Re: Photoshop opening file
Re: Photoshop opening file
- Subject: Re: Photoshop opening file
- From: Thomas <email@hidden>
- Date: Thu, 30 Jan 2003 23:18:16 +0100
You pix variable just contains the name of your files, Photoshop needs a
file path as string (not as alias) to open the files.
Also do a "list folder without invisibles" to avoid problems with files
like ".DS_Store".
This will do the trick :
on open theFolder
set itemList to list folder theFolder without invisibles
repeat with an_item in itemList
set file_path to ((theFolder as string) & an_item) as string
tell application "Adobe. Photoshop. 5.5"
activate
open file file_path
do script "page1"
end tell
end repeat
end open
Thomas
Rick Norman wrote :
Can someone tell me what I'm missing here.
Thanks,
Rick
on open theFolder
set itemList to list folder theFolder
set X to 1
repeat with an_item in itemList
set pix to item X in itemList as string
tell application "Adobe. Photoshop. 5.5"
activate
--> Tried this with these results.
open file pix --> The error returned with this is "Some
object
wasn't found"
--> Tried this with these results.
open file (the file pix as string) --> The error returned
with
this is "Can't make file "filename" of "Adobe. Photoshop. 5.5" into a
string.
do script "page1"
end tell
set X to X + 1
end repeat
end open
_______________________________________________
applescript-users mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/applescript-users
Do not post admin requests to the list. They will be ignored.