GraphicConverter, iPhoto & IPTC Tags Help Needed
GraphicConverter, iPhoto & IPTC Tags Help Needed
- Subject: GraphicConverter, iPhoto & IPTC Tags Help Needed
- From: Brett <email@hidden>
- Date: Mon, 2 Aug 2004 19:15:42 -0400
I'm trying to use GraphicConverter to make iPhoto comments & keywords
more permanent. I can pretty easily and successfully take the iPhoto
keywords and have GC put them into IPTC tags. What I can't seem to get
GC to do is put anything from iPhoto into the IPTC caption or other
IPTC tags. I get a "Some data was the wrong type" error. The dictionary
calls for international text, but doesn't seem to take any variable.
Below is my script. For simplicity's sake, it does its magic on the 1st
selected photo in iPhoto- any help would be greatly appreciated.
-- --------------------------------------------------------
global the_Comment, theKeywords, thePath
tell application "iPhoto"
copy selection to thePhotosToProcess
set this_image to item 1 of thePhotosToProcess
set the_Comment to (comment of this_image)
set thePath to image path of this_image
end tell
set theAlias to (thePath as POSIX file) as alias
tell application "GraphicConverter"
activate
-- Use IPTC captions
open theAlias
-- The following line works fine
set IPTC caption of window 1 to "test"
-- The following line fails with
-- "GraphicConverter got an error: Some data was the wrong type."
-- set IPTC caption of window 1 to (the_Comment as international text)
-- The following line fails with
-- "GraphicConverter got an error: Some data was the wrong type."
-- set IPTC caption of window 1 to (the_Comment) as string
-- The following line fails with
-- "GraphicConverter got an error: Some data was the wrong type."
-- tell AppleScript to set testComment to (the_Comment as string)
-- set IPTC caption of window 1 to testComment
-- The following works...
set tmpComment to "test"
set IPTC caption of window 1 to tmpComment
-- The following works...
set IPTC caption of window 1 to (month of (current date)) as string
end tell
------------------------
There are 10 kinds of people in the world; those who understand binary,
and those who don't
_______________________________________________
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.