Monday, September 16, 2019

#1 2019-05-19 03:25:40 am

Grant Symon
Member
Registered: 2004-06-01
Posts: 38

Help with a script to change image date to import date in Aperture

Hi,

I'm trying to do some cleaning up of my Aperture libraries, to prepare for moving to another solution (since Apple have finally dumped us pros completely, having recently announced that Aperture, which is 64bit, won't run in MacOS 10.15).

Specifically, I'm trying to work out how to alter one of the scripts that Apple provides in the Aperture Applescript Dictionary in order to do something that I guess should be very simple:

• Set File Date to Import Session (date)

My problem is getting the tag for the Import Session to be recognised when I run the script.  The "Aperture_3_AppleScript_Reference.pdf" says this about the tag:

(PDF can still be found here - https://bit.ly/2JsVIR6)



Aperture other tag naming


I'm trying to use this example script that I found in the Script Editor's Aperture Dictionary, for changing the File Date:


Example
The following script adjusts the EXIF image date of a selection of image versions by decreasing the hour by one.

Applescript:


tell application "Aperture"
set imageSel to (get selection)
repeat with i from 1 to count of imageSel
tell item i of imageSel
set imageDate to value of EXIF tag "ImageDate"
end tell
set imageDate to imageDate - (1 * hours)
adjust image date imageDate of images {item i of imageSel}
end repeat
end tell

There is another point, which is that the format of the 2 date fields is slightly different and I don't know, but I'm guessing that the EXIF one might not work correctly if it's not in a standard format?


Aperture date formats


Can anyone help me put these 2 things together and save me many many hours of manual labour?? smile smile

Model: MBPro
AppleScript: 2.7
Browser: Safari 605.1.15
Operating System: macOS 10.14


Filed under: aperture, imageDate

Offline

 

Board footer

Powered by FluxBB

RSS (new topics) RSS (active topics)