Looks like no one’s replied in a while. To start the conversation again, simply ask a new question.

Question:

Question: Photos & AppleScript: get the path of the referenced file of a photo

Is it possible to get the path of the referenced file of a photo in Photos with AppleScript ?

iMac, iOS 11.2.6

Posted on

Reply
Question marked as Solved
Answer:
Answer:

The scripting interface of Photos does not have a command to retrieve the path to a referenced file. You can only return the filename of the original file.

Posted on

There’s more to the conversation

Read all replies

Page content loaded

Mar 9, 2018 9:44 AM in response to LarryHN In response to LarryHN

Thanks for you answers.

I wanted to write a script to open a raw file (with the same name as the JPEG one imported in Photos) in a raw editor directly from Photos so I need the path of the JPEG photo to calculate the path of the RAW photo. I will continue to open it from the finder, it's not so difficult ;-) Excuse me for my bad english (I'm french).

Mar 9, 2018 9:44 AM

Reply Helpful

Mar 9, 2018 10:09 AM in response to EnezHouad In response to EnezHouad

If you import all RAW files to the same folder, you could create the path to the RAW file from the JPEG filename and then append this filename to the path to the folder.

This script will show you how to retrieve the filename of a selected photo: https://discussions.apple.com/docs/DOC-8414

Mar 9, 2018 10:09 AM

Reply Helpful
User profile for user: EnezHouad

Question: Photos & AppleScript: get the path of the referenced file of a photo