Hi,
I’m rather new to this forum and also using Mac! But i like it a lot so far!
I’m trying to create an applescript that prompts for a PDF to open each page to convert them.
But I can’t even manage to get the open PDF to work. This is what I got so far:
tell application “Adobe Photoshop CS5”
set new_file to choose file with prompt “Open PDF to open” of type (“PDF”)
with timeout of 180 seconds
open new_file as PDF with options {class:PDF open options, height:pixels 1000, width:pixels 1000, mode:RGB, resolution:72, use antialias:true, page:1, constrain proportions:false}
end timeout
end tell
I get error -43 and I don’t really get why. Can anyone tell me what’s wrong?
OK, thanks. I took the example from PhotoShop CS5 Applescript document:
tell application “Adobe Photoshop CS5”
set display dialogs to never
set myFilePath to alias “Data:docsamples:testfiles:PdfTest.pdf”
open myFilePath as PDF with options ¬
{class:PDF open options, height:pixels 100, width:pixels 200, mode:RGB,¬
resolution:72, use antialias:true, page:1, constrain proportions:false}
end tell
I also try just to open with:
open new_file as PDF with options {class:PDF open options, page:1}
But get the same error. Anyone knows which parameters I can and must use to open the PDF in PS CS5?
I’m not sure about the photoshop part, however if you can’t figure it out then you can at least first convert the pdf to tif or jpg, and then open those converted files using photoshop. See here to get a start… http://macscripter.net/viewtopic.php?id=25350