saving a file in GraphicConverter
saving a file in GraphicConverter
- Subject: saving a file in GraphicConverter
- From: Joel Henriques <email@hidden>
- Date: Sun, 5 Jan 2003 17:11:00 -0800
I've been working on my droplet to save tiff files to jpeg, and with
lots of help from everyone (especially Mr Tea) I'm getting pretty darn
close. I can get the files to open in GraphicConverter, and the new
destination folder for the jpegs is created, but it's not making any
new jpeg files, or any error pop-ups. Does anyone see any obvious
problems?
property type_list : {"JPEG", "GIFf", "PICT", "TIFF"}
property extension_list : {"jpg", "gif", "pct", "tif"}
on open these_items
tell application "Finder"
set theLoc to container of item 1 of these_items
set theDest to (make new folder at theLoc with properties
{name:"JPEGs"}) as alias
end tell
repeat with i from 1 to the count of these_items
set this_item to item i of these_items
set the item_info to info for this_item
set theName to name of (info for this_item)
set theNewName to text item 1 of theName & ".jpg"
if (folder of the item_info is false) and ,
(alias of the item_info is false) and ,
((the file type of the item_info is in the type_list) or ,
the name extension of the item_info is in the extension_list) then
tell application "GraphicConverter"
open this_item
set this_item to ((theDest as string) & theNewName)
save window 1 in this_item as JPEG with makeCopy
close window 1 saving no
end tell
end if
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.