Trying to use Applescript to save for web
I am fairly new to Applescript and have been getting frustrated trying to build a script that:
1) converts a PDF to pixels
2) flattens the image
3) saves the image via Save for Web (JPEG, quality 60)
4) saves the file to the Desktop using the original file name
I have managed the first two, but am totally stumped on the last two. Currently my script is:
set XXres to 85
tell application "Adobe Photoshop CS4"
set XXfile to choose file with prompt "Open file to be edited"
open XXfile as PDF with options {class:PDF open options, mode:RGB, resolution:XXres, use antialias:true, page:1, constrain proportions:true}
delay 1
flatten current document
end tell
All my attempts and online searches for samples have produced negative results, any help would be greatly appreciated.
Many thanks
Roger
