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

batch title change in photo version 1

The new "Photo" has changed the user interface completely. Is there a way to to the "batch title change" for a group of photos? There are instructions for how to do for one, but I'm hoping that this has not been lost. I'm using version 1.


Is there any way to remove the conformation that is now required each and every time you want to delete a photo or group of photos?


Thanks,


DMW

Posted on Apr 24, 2015 9:56 AM

Reply
35 replies

Apr 26, 2015 9:17 AM in response to Jay Deitch

Hi Léonie,

I found another post of yours about rebuilding the iPhoto Library using iPhoto Library Manager. I tried it (took all night), and it found a few photos that couldn't be imported to the rebuilt library. It looked fine in iPhoto so I opened that library in Photos. I get the same error when running the script. I can't think anything else to try. Maybe I'll just stick with iPhoto.

-Jay

Apr 26, 2015 9:24 AM in response to Jay Deitch

I forgot to include this...


Here are the Console messages I get when I run the script. The first two happen as soon as I open the script. The other three appear after I type in the title text:


4/26/15 11:20:05.227 AM Automator Runner[2841]: -[AMApplicationRegistry loadDefinitionAtURL:]: No application name for definition at URL file:///Library/Automator/Office.definition/

4/26/15 11:20:05.227 AM Automator Runner[2841]: -[AMApplicationRegistry _loadDefinitionsAtURLS:]: Failed to load definition at URL file:///Library/Automator/Office.definition/

4/26/15 11:20:42.006 AM Photos[2832]: An exception was thrown during execution of an NSScriptCommand...

4/26/15 11:20:42.006 AM Photos[2832]: *** -[__NSArrayM objectAtIndex:]: index 47333 beyond bounds for empty array

4/26/15 11:20:42.384 AM WorkflowServiceRunner[2840]: WorkflowServiceRunner received error running Workflow Service at /Users/Jay/Library/Services/Batch Change Titles.workflow: The action “Run AppleScript” encountered an error.


-Jay

Apr 26, 2015 12:37 PM in response to léonie

HI,


With Activity Monitor open, "Activity Runner shows up when I launch the script from the Photos > Services menu. It goes away as soon as I get the error message:


User uploaded file


If I open Automator (with Photos open and the photos still selected), Automator is shown in Activity Monitor and stays there until I close it (as it should). If I execute the workflow from Automator I get a different error message:


User uploaded file


Since the script worked fine with a small, test Photos library, the problem is probably with the default Photos library (which is now named "Default Library (rebuilt)").


I get a nice collection of Console messages while doing this:


4/26/15 2:30:07.615 PM WorkflowServiceRunner[3005]: Failed to connect (colorGridView) outlet from (NSApplication) to (NSColorPickerGridView): missing setter or instance variable

4/26/15 2:30:07.615 PM WorkflowServiceRunner[3005]: Failed to connect (view) outlet from (NSApplication) to (NSColorPickerGridView): missing setter or instance variable

4/26/15 2:30:07.650 PM WorkflowServiceRunner[3005]: -[AMApplicationRegistry loadDefinitionAtURL:]: No application name for definition at URL file:///Library/Automator/Office.definition/

4/26/15 2:30:07.650 PM WorkflowServiceRunner[3005]: -[AMApplicationRegistry _loadDefinitionsAtURLS:]: Failed to load definition at URL file:///Library/Automator/Office.definition/

4/26/15 2:30:07.724 PM Automator Runner[3006]: -[AMApplicationRegistry loadDefinitionAtURL:]: No application name for definition at URL file:///Library/Automator/Office.definition/

4/26/15 2:30:07.724 PM Automator Runner[3006]: -[AMApplicationRegistry _loadDefinitionsAtURLS:]: Failed to load definition at URL file:///Library/Automator/Office.definition/

4/26/15 2:30:16.659 PM Photos[2997]: An exception was thrown during execution of an NSScriptCommand...

4/26/15 2:30:16.659 PM Photos[2997]: *** -[__NSArrayM objectAtIndex:]: index 48158 beyond bounds for empty array

4/26/15 2:30:17.084 PM WorkflowServiceRunner[3005]: WorkflowServiceRunner received error running Workflow Service at /Users/Jay/Library/Services/Batch Change Titles.workflow: The action “Run AppleScript” encountered an error.


The messages at 2:30:07 are from running the workflow from Automator, the others are from running the scrips from Photos > Services.

-Jay

May 3, 2015 3:13 PM in response to Jay Deitch

Hi again,


I was reading through another thread - Where are photo file names? and inverseroom commented (pg. 5): "Wait a minute, I just found that when I select images in the Photos tab, the script won't work, but when I select them in albums > all photos, it does." So I tried that with the script described in this thread (to batch change the titles) and it worked! I've only tried it once, but once is one more time than it has ever worked before for me!


Jay

May 4, 2015 2:31 PM in response to Old Toad

Hi,


I changed the titles on 100 photos in about 30 seconds on a mid 2011 MacBook Air with a 1.6 GHz Intel Core i5 processor.


I'm using Léonie's original script:


on run {input, parameters}

-- batch change the title to the input

tell application "Photos"

activate

set imageSel to (get selection)

if imageSel is {} then

error "Please select an image."

else

repeat with im in imageSel

tell im

set the name to input

end tell

end repeat

end if

end tell

return input

end run



-- Jay


o

Model Name:

May 12, 2015 4:37 AM in response to Jay Deitch

Thanks Jay,

I also copied/made that Applescript, and it worked perfectly.

But today the Automator Service no longer worked, so I built it again. Alas...

Then I came across this text of yours [quote]"Wait a minute, I just found that when I select images in the Photos tab, the script won't work, but when I select them in albums > all photos, it does."[/quote]

And indeed, I switched to Albums>All Photos and it worked.

So I'm a happy camper again.


Is there no way to change the script so that it either switches to Albums>All Photos, or tells the user to do that first?

Aug 26, 2015 9:01 AM in response to Old Toad

As stated in another post the script will work when run on pictures selected in Albums > All Photos. While this is helpful it isn't entirely helpful for me. Is there a way for the script to work within a particular Album? I have several pictures perhaps from different times all in one album. It's not feasible for me to select these pictures in Albums > All Photos to do the batch rename. Instead it would make sense to select all within the album.


Thank you all for the scripts. Any way we can modify so it can be run in an album? Thanks.

Aug 26, 2015 10:01 AM in response to Old Toad

Thanks for the quick response. I just ran the top code (Batch Change Title to Text w/Padded Sequential No) and it will not complete for me. I get the following error in Automator:

The action "Run AppleScript" encountered an error. Check the action's properties and try running the workflow again. (listed in log as AppleEvent handler failed)


The test album I created to run the code was not in a folder. Also in an attempt to trouble shoot I used the exact code but selected pictures in Albums > All Photos and it ran fine.


What am I doing wrong? Perhaps some sort of setting?

batch title change in photo version 1

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple ID.