Re: P/shop five file format
Re: P/shop five file format
- Subject: Re: P/shop five file format
- From: Mr Tea <email@hidden>
- Date: Thu, 28 Mar 2002 15:24:47 +0000
This from John McMillan - dated 28/3/02 11:07 am:
>
on open fileList
>
repeat with oneFile in fileList
>
set oneFile to oneFile as string
>
if oneFile does not end with ".c" and oneFile does not end with ".m"
>
and oneFile does not end with ".y" and oneFile does not end with
>
".k" then
>
move oneFile to "PSHOP DROP"
>
end if
>
end repeat
>
end open
Hi, John.
I've tidied up the code for checking cmyk suffixes and put in the machinery
for opening files with a photoshop droplet. Replace my alias with the path
to your droplet, and you're away.
on open fileList
repeat with oneFile in fileList
set theColour to (text -2 thru -1) of name of (info for oneFile)
if theColour is not in {".c", ".m", ".y", ".k"} then
tell application "Finder"
open oneFile using alias "Basement!:Desktop Folder:Shrink to 50%"
end tell
end if
end repeat
end open
NB. It might be more efficient to generate a list of files that don't
contain the cmyk suffixes before processing. Wiser heads than mine know
about that sort of stuff.
If you need to generate a path to the Photoshop droplet that you can paste
your script, paste the following into a new script editor document and save
as an application. The path to any item you drag onto the resulting droplet
will be saved to the clipboard, complete with quotation marks, ready for
pasting.
on open
set the clipboard to "\"" & (selection of application "Finder" as
string) & "\""
end open
HTH
Mr Tea
--
_______________________________________________
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.