Hello, I have a strange thing happening. I made a little script to open a PDF in Illustrator, then resave it as PDF with a PDF preset. The original size of my file is 2.3 mb. If I do it manually, opening and resaving with PDF preset the size increase to 6 mb, which is normal due to the fact that I changed the color mode to CMYK instead of RGB. But when I do the same work using my script, the file size increase to 113 mb. Can somebody tell me why?
is there a way to get all the properties from that PDF preset so I can put them in the script instead of using only (PDF Preset:[PDF/X-4:2008]" ?
Here’s how I save the file using the script:
save current document in file FinalName as pdf with options {class:PDF save options, PDF preset:"[PDF/X-4:2008]"}
I don’t want the size to increase like that, I have too many files to do.
set SaveToDeskTop to ((path to desktop) as string)
set GetAIfile to choose file
set FinalName to SaveToDeskTop
tell application "Adobe Illustrator"
activate
open GetAIfile without dialogs
save current document in file FinalName as pdf with options {class:PDF save options, compatibility:Acrobat 5, preserve editability:true, color resample:bicubic downsample, color downsampling:20, color compression:automatic JPEG medium}
close current document saving no
end tell
Thanks Budgie, I found out what was the difference for my file size. It’s the option (preserve edit ability) that has to be set to false. Everything’s work great now.