Professional Web Applications Themes

batch ill files to PDF Files w/ ".pdf" extension included - Adobe Illustrator Macintosh

when using illustrators action palette to make batch PDF files, only one of the 30 files in the batch has the ".pdf" extension added to it... and the action includes the "append file extension" dialog... to have to go back and manually add the ".pdf" to each of the remaining files involves too much time... any suggestions on how to have all the "batched" files inlude the .pdf extension OR is there a quciker way to manually add the ".pdf" extension?? thanks...

  1. #1

    Default batch ill files to PDF Files w/ ".pdf" extension included

    when using illustrators action palette to make batch PDF files, only one of the 30 files in the batch has the ".pdf" extension added to it... and the action includes the "append file extension" dialog... to have to go back and manually add the ".pdf" to each of the remaining files involves too much time...

    any suggestions on how to have all the "batched" files inlude the .pdf extension OR is there a quciker way to manually add the ".pdf" extension??

    thanks
    Stephen_Finney@adobeforums.com Guest

  2. #2

    Default Re: batch ill files to PDF Files w/ ".pdf" extension included

    Try this


    --Open this script in a new Script Editor window (OS X Panther users only) <applescript://com.apple.scripteditor?action=new&script=on%20open %20dropped_items_%0A%09repeat%20with%20dropped_ite m_%20in%20dropped_items_%0A%09%09set%20dropped_ite m_info_%20to%20info%20for%20dropped_item_%0A%09%09 if%20file%20type%20of%20dropped_item_info_%20%3D%2 0%22PDF%20%22%20and%20name%20extension%20of%20drop ped_item_info_%20%AD%20%22pdf%22%20then%0A%09%09%0 9set_filename_extension_(dropped_item_,%20dropped_ item_info_)%0A%09%09end%20if%0A%09end%20repeat%0Ae nd%20open%0A%0Aon%20run%0A%09set%20chosen_files_%2 0to%20%7B%7D%0A%09set%20folder_%20to%20choose%20fo lder%20with%20prompt%20%22Choose%20the%20folder%20 of%20files%20to%20process%3A%22%0A%09set%20folder_ path_%20to%20folder_%20as%20string%0A%09set%20list _folder_%20to%20list%20folder%20folder_%20without% 20invisibles%0A%09repeat%20with%20item_name_%20in% 20list_folder_%0A%09%09set%20end%20of%20chosen_fil es_%20to%20((folder_path_%20%26%20item_name_)%20as %20alias)%0A%09end%20repeat%0A%09repeat%20with%20c hosen_file_%20in%20chosen_files_%0A%09%09set%20cho sen_file_info_%20to%20info%20for%20chosen_file_%0A %09%09if%20file%20type%20of%20chosen_file_info_%20 %3D%20%22PDF%20%22%20and%20name%20extension%20of%2 0chosen_file_info_%20%AD%20%22pdf%22%20then%0A%09% 09%09set_filename_extension_(chosen_file_,%20chose n_file_info_)%0A%09%09end%20if%0A%09end%20repeat%0 Aend%20run%0A%0Aon%20set_filename_extension_(item_ ,%20item_info_)%0A%09set%20file_name_%20to%20name% 20of%20item_info_%0A%09tell%20application%20%22Fin der%22%0A%09%09try%0A%09%09%09set%20name%20of%20it em_%20to%20(file_name_%20%26%20%22.pdf%22)%0A%09%0 9on%20error%20error_message_%20number%20error_numb er_%0A%09%09%09display%20dialog%20error_message_%2 0%26%20return%20%26%20return%20%26%20error_number_ %0A%09%09end%20try%0A%09end%20tell%0Aend%20set_fil ename_extension_%0A%0A%0A>.


    on open dropped_items_
    repeat with dropped_item_ in dropped_items_
    set dropped_item_info_ to info for dropped_item_
    if file type of dropped_item_info_ = "PDF " and name extension of dropped_item_info_ ` "pdf" then
    set_filename_extension_(dropped_item_, dropped_item_info_)
    end if
    end repeat
    end open

    on run
    set chosen_files_ to {}
    set folder_ to choose folder with prompt "Choose the folder of files to process:"
    set folder_path_ to folder_ as string
    set list_folder_ to list folder folder_ without invisibles
    repeat with item_name_ in list_folder_
    set end of chosen_files_ to ((folder_path_ & item_name_) as alias)
    end repeat
    repeat with chosen_file_ in chosen_files_
    set chosen_file_info_ to info for
    Mark_Douma@adobeforums.com Guest

  3. #3

    Default Re: batch ill files to PDF Files w/ ".pdf" extension included

    Save the following as an application in Script Editor, with all the "Options:" unchecked, then drop your files onto it, or double-click it to run it (you'll be prompted to choose a folder that has the files to process). When using it as a droplet, select a bunch of files to be processed and drop those (rather than a folder that has files in it--this script can't process the contents of a folder).

    on open dropped_items_
    repeat with dropped_item_ in dropped_items_
    set dropped_item_info_ to info for dropped_item_
    if file type of dropped_item_info_ = "PDF " and name extension of dropped_item_info_ is not equal to "pdf" then
    set_filename_extension_(dropped_item_, dropped_item_info_)
    end if
    end repeat
    end open

    on run
    set chosen_files_ to {}
    set folder_ to choose folder with prompt "Choose the folder of files to process:"
    set folder_path_ to folder_ as string
    set list_folder_ to list folder folder_ without invisibles
    repeat with item_name_ in list_folder_
    set end of chosen_files_ to ((folder_path_ & item_name_) as alias)
    end repeat
    repeat with chosen_file_ in chosen_files_
    set chosen_file_info_ to info for chosen_file_
    if file type of chosen_file_info_ = "PDF " and name extension of chosen_file_info_ is not equal to "pdf" then
    set_filename_extension_(chosen_file_, chosen_file_info_)
    end if
    end repeat
    end run

    on set_filename_extension_(item_, item_info_)
    set file_name_ to name of item_info_
    tell application "Finder"
    try
    set name of item_ to (file_name_ & ".pdf")
    on error error_message_ number error_number_
    display dialog error_message_ & return & return & error_number_
    end try
    end tell
    end set_filename_extension_
    ------------------

    Hope this helps.....
    Mark_Douma@adobeforums.com Guest

  4. #4

    Default Re: batch ill files to PDF Files w/ ".pdf" extension included

    Thanks for the help Mark the script worked! Another question though - is there any way i can add (or cut/paste) the script into the Action that gets Batch Processed?
    I'd like to have it all in on Action/Script instead of having to add another "step" in the process.....

    Thanks Alot!!
    Stephen_Finney@adobeforums.com Guest

Similar Threads

  1. Acrobat 8 Combine Files - Word, Excel = "Problem Files" Any help?
    By Matthew_Chagnon@adobeforums.com in forum Adobe Acrobat Macintosh
    Replies: 5
    Last Post: January 25th, 09:58 PM
  2. "couldn't find files" connecting to subversion repo viaWebDAV
    By whit537 in forum Macromedia Contribute Connection Administrtion
    Replies: 1
    Last Post: September 8th, 08:07 PM
  3. Batch Renamed my Files, cannot be opened as "Unix Executable File"
    By Ed_Gerson@adobeforums.com in forum Adobe Photoshop Mac CS, CS2 & CS3
    Replies: 2
    Last Post: April 9th, 09:04 PM
  4. Replies: 0
    Last Post: November 12th, 10:58 PM
  5. Forcing export "FRAMES TO FILES" in a BATCH process?
    By Dave in forum Macromedia Fireworks
    Replies: 0
    Last Post: September 29th, 07:27 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139