Running scripts in Aperture

Aperture appears to have the facility to run scripts during the import stage (it's called 'Action' in the import pop up menu), but I'm having problems with it.
I have successfully run the script below, and have exported the subsequent metadata to the master, which is my aim.
But I cannot get the script run via this 'Actions' facility during import, even importing into a second library after the 'Object Name' field (called 'Title' by Aperture) has been created in the file and contains a 'space'.
Can anyone show me what I am doing wrong?
I found the script at: How can I set the Object Name to the file name on import?
The post reads:
AppleScript to the rescue!
1. Copy the following text into Script Editor:
tell application "Aperture"
set selectedImages to the selection
set tName to name of item 1 of selectedImages
repeat with i from 1 to number of items in selectedImages
set this_item to item i of selectedImages
set tName to name of this_item
set value of IPTC tag "ObjectName" of this_item to tName
end repeat
end tell
2. Save the script in a sensible place, such as ~/Library/Scripts/Aperture Scripts so that it will turn up in the Script Menu (if it's enabled).
3. Select a bunch of images in Aperture.
4. IMPORTANT! You must use Batch Change to put a value into the Object Name tag (such as " "), until you do so the tag doesn't exist for those images and therefore cannot be altered.
5. Run the AppleScript, it should loop through all the selected versions and put the version name into the Object Name tag.
Note - the Master File Name isn't accessible via AppleScript, only the Version Name.
Ian
P.S. As with all such scripts, test it on a small number of 'spare' versions before doing anything drastic...
Help!

I haven't. Have you tried making a droplet to run at the end of the LR export?

Similar Messages

  • How Do I Run AppleScripts In Aperture?

    I want to copy the Version Name to the Object Name field without having to manually type it for each image...
    Here is the script I am attempting to run:
    tell application "Aperture"
    set selectedImages to the selection
    repeat with i in selectedImages
    set tName to name of i
    set value of IPTC tag "ObjectName" of i to tName
    end repeat
    end tell
    (I copied the script from this thread: http://discussions.apple.com/thread.jspa?messageID=4458642.)
    I enabled the Script Menu to appear in the Finder Menu Bar, but that is as far as I have been able to get. I tried selecting a couple of images in Aperture, then selected Batch Change/IPTC Basic. I then selected the script in the Script Menu and clicked "OK." Nothing appears to get transferred in the two selected image files metadata. I also tried running the script without going to Batch Change and Still No Go...
    I think that my problem has to do with this step from the linked thread, but I am unclear as to what it means:
    4. IMPORTANT! You must use Batch Change to put a value into the Object Name tag (such as " "), until you do so the tag doesn't exist for those images and therefore cannot be altered.
    I have been through the Aperture Manual, Apple Aperture Digital Workflow book, etc. but I have been unable to figure out how to make this work.
    Message was edited by: MisterMojo
    Message was edited by: MisterMojo

    Since you have OS 10.5.8, do you also use an older Aperture version? Most people have latest OS and Aperture, so you might get more answers if we knew what your version of Aperture is...
    Well, I am running OS 10.6.2 and Aperture 2.1.4
    I found the script you posted to be non-functional. After digging around and some Googling, I came up with the following script that works for me. Keep in mind you are using a different OS version, but my point is, with some research and trial&err you should be able to do the same. I don't know anything about scripting, all I did was read into its meaning and substitute some terms. I basically stole the code and changed a couple of variables...
    tell application "Aperture"
    copy selection to theSel
    repeat with theImg in theSel
    tell theImg
    set MyVersionName to (get value of other tag "VersionName" of theImg)
    make new IPTC tag with properties {name:"ObjectName", value:MyVersionName}
    end tell
    end repeat
    end tell
    Notice how the script temporarily (?) creates a variable called MyVersionName, as a place to hold the value copied over from VersionName. Apparently scripts ignore the spaces in field names. It then uses the value from MyVersionName to fill in the ObjectName. The script is set to repeat for each image selected, one by one. I don't know why it's written like that, but it works.
    The above script works for both single and multiple selections of images. Pase it into AppleScript Editor, run it, save it in the Aperture folder which is a straight shot from the Save As... menu in the AppleScript Editor. (Users> {you}> Library> Scripts> Applications> Aperture)
    In the ASEditor's Preferences, make sure to check boxes so the scripts appear in the menu bar. Close the Editor. Back to Aperture, your (appropriately-named) script should show up from a drop-down at the menu bar under the AppleScript icon. Test it on a couple of inages. Mine works.

  • HT4759 can sign into icloud but won`t let me in . says wont open because of long running script . any ideas

    Can sign into icloud but wont let me in . says wont open due to lond running script . any ideas thanks

    Restart your PC and try again.

  • Run Script action not working when verifying bundle

    I have a critical "Run Script" action in a bundle. When verifying the bundle, the script doesn't seem to run and the verify action hangs indefinitely.
    I see the following lines in the ZCM Log:
    Code:
    [DEBUG] [07/21/2011 19:05:48.670] [5880] [runscriptenf] [1] [TeachGH] [Run Script Action] [] [Found script engine cmd.exe. Not using it since cmd.exe does not take parameters.] [] []
    [DEBUG] [07/21/2011 19:05:58.311] [5880] [runscriptenf] [1] [TeachGH] [Run Script Action] [] [Run Script Action - Ended - 7:05:58 PM] [] []
    nothing else is logged after those 2 lines. It seems like ZCM decides not to run the script for some reason, but is still waiting for it to complete? Or is it possible that it has moved onto the next action, but it is hanging there and not reporting it to the log?
    I have no time to troubleshoot right now, will do so in depth tomorrow. Just wanted to get this posted in case anybody has a clue.

    Nevermind, the next action is running, and that is what is hanging, which I doubt is Zenworks fault... Time for some more troubleshooting.

  • "Run Scripts" giving a problem to create portal domain

    Hello All.
    I am new to weblogic portal development. Was trying to create my basic sample portal in weblogic_portal_10.3.4 with the help of documentation. I am getting in running scripts when I was creating the domain. I have followed the below steps, please help me if you find any issue with my steps.
    1. downloaded Weblogic_Portal_10.3.4 and installed in my windows 7 environment.
    2. launched eclipse for weblogic portal.
    3. opened portal prospective in eclipse.
    4. right click on server tab and selected "Oracle WebLogic Server 11gR1 (10.3.4)"
    5. opened "Domain Configuration Wizard"
    6. Selected "Create a new Weblogic domain" radio button.
    7. in the next screen for "Generate a domain configured automatically to support the following products"
    selected "Weblogic Portal 10.3.4" radio button
    8. in the next screen given the domain_name
    9. in the next screen provided the password/confirm-password for administrator user
    10. in the next screen selected JRocket SDK and development_mode for my domain.
    11. in the next screen just left all the default configuration for the datasources. ( non of the datasource is selected in their check boxes)
    12. in the next screen just clicked on "Next" button and "OK" on my popup
    13. in this screen "p13nDataSource" is selected on my left top window area, All 3 SQL Files are selected for loading database.
    Clicked on *"Run Scripts"*
    At this point i am getting an error saying : "CFGFWK-60839:  Database Load Failed!"
    java.lang.Exception: SQLException when executing file file:/C:/Oracle/Middleware/wlportal_10.3/p13n/db/derby/seq_drop_tables.sql
         at com.oracle.cie.domain.jdbc.JDBCDataLoader.load(JDBCDataLoader.java:183)
         at com.oracle.cie.wizard.domain.gui.tasks.JDBCConfigGUITask$LoadDatabaseThread$1.run(JDBCConfigGUITask.java:1673)
    Caused by: java.sql.SQLNonTransientConnectionException: java.net.ConnectException : Error connecting to server localhost on port 1527 with message Connection refused: connect.
         at org.apache.derby.client.am.SQLExceptionFactory40.getSQLException(Unknown Source)
         at org.apache.derby.client.am.SqlException.getSQLException(Unknown Source)
         at org.apache.derby.jdbc.ClientDriver.connect(Unknown Source)
         at com.oracle.cie.domain.jdbc.JDBCConnectionTester.createConnection(JDBCConnectionTester.java:272)
         at com.oracle.cie.domain.jdbc.JDBCDataLoader.load(JDBCDataLoader.java:154)
         ... 1 more
    Caused by: org.apache.derby.client.am.DisconnectException: java.net.ConnectException : Error connecting to server localhost on port 1527 with message Connection refused: connect.
         at org.apache.derby.client.net.NetAgent.<init>(Unknown Source)
         at org.apache.derby.client.net.NetConnection.newAgent_(Unknown Source)
         at org.apache.derby.client.am.Connection.<init>(Unknown Source)
         at org.apache.derby.client.net.NetConnection.<init>(Unknown Source)
         at org.apache.derby.client.net.NetConnection40.<init>(Unknown Source)
         at org.apache.derby.client.net.ClientJDBCObjectFactoryImpl40.newNetConnection(Unknown Source)
         at org.apache.derby.jdbc.ClientDriver.connect(Unknown Source)
         at com.oracle.cie.domain.jdbc.JDBCConnectionTester.createConnection(JDBCConnectionTester.java:273)
         at com.oracle.cie.domain.jdbc.JDBCDataLoader.load(JDBCDataLoader.java:154)
         at com.oracle.cie.wizard.domain.gui.tasks.JDBCConfigGUITask$LoadDatabaseThread$1.run(JDBCConfigGUITask.java:1674)
    Caused by: java.net.ConnectException: Connection refused: connect
         at java.net.PlainSocketImpl.socketConnect(Native Method)
         at java.net.PlainSocketImpl.doConnect(PlainSocketImpl.java:333)
         at java.net.PlainSocketImpl.connectToAddress(PlainSocketImpl.java:195)
         at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:182)
         at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:366)
         at java.net.Socket.connect(Socket.java:529)
         at java.net.Socket.connect(Socket.java:478)
         at java.net.Socket.<init>(Socket.java:375)
         at java.net.Socket.<init>(Socket.java:189)
         at javax.net.DefaultSocketFactory.createSocket(SocketFactory.java:206)
         at org.apache.derby.client.net.OpenSocketAction.run(Unknown Source)
         at org.apache.derby.client.net.NetAgent.<init>(Unknown Source)
         at org.apache.derby.client.net.NetConnection.newAgent_(Unknown Source)
         at org.apache.derby.client.am.Connection.<init>(Unknown Source)
         at org.apache.derby.client.net.NetConnection.<init>(Unknown Source)
         at org.apache.derby.client.net.NetConnection40.<init>(Unknown Source)
         at org.apache.derby.client.net.ClientJDBCObjectFactoryImpl40.newNetConnection(Unknown Source)
         at org.apache.derby.jdbc.ClientDriver.connect(Unknown Source)
         at com.oracle.cie.domain.jdbc.JDBCConnectionTester.createConnection(JDBCConnectionTester.java:272)
         at com.oracle.cie.domain.jdbc.JDBCDataLoader.load(JDBCDataLoader.java:154)
         at com.oracle.cie.wizard.domain.gui.tasks.JDBCConfigGUITask$LoadDatabaseThread$1.run(JDBCConfigGUITask.java:1673)
    CFGFWK-60839:  Database Load Failed!
    Please help me if you find any problem with the steps that I am following to create my weblogic_portal_domain.
    I was following the steps mentioned at : http://docs.oracle.com/cd/E15919_01/wlp.1032/e14252.pdf to create my domain to start portal development.

    Those are the WLP 10.3.2 instructions. But, the 10.3.4 instructions in the tutorial (http://docs.oracle.com/cd/E26806_01/wlp.1034/e14252/setup_dev_env.htm#i1014619) are wrong, too.
    In 10.3.4, with derby, Run Scripts doesn't work any longer; it should still work the other database (Oracle, SQL Server, etc.). Instead, for derby, just create the domain, accepting any warning dialogs about databases that come up. After that finishes, in the domain directory, run create_db.cmd (on windows) or create_db.sh (on *nix and Mac). It should create the derby database files in the domain, and include everything needed.
    I'll send a note to get the docs updated.
    Greg

  • HT1222 hi i have a apple imac 27 2009 and i have purchased mountain lion but near the end it says An error occurred while running scripts from the package "mzps6175750011235388779.pkg"

    hi i have a apple imac 27 2009 and i have purchased mountain lion but near the end it says An error occurred while running scripts from the package “mzps6175750011235388779.pkg”
    can you please advise me what should i do to fix this

    Some ideas.
    https://discussions.apple.com/message/20034600#20034600

  • Can't access icloud due to long running script

    keep getting this error message when logging on to icloud to access my email:
    can't access icloud due to long running script
    And if I do get logged into icloud and try to open the email application I can't open my email or any other applicationii.
    HELP

    Welcome to the Apple Community.
    Delete your mail account from Mail preferences and set it up again using the Mail Server Information.
    Some users have apparently encountered issues using this information in pre-Lion set ups (I haven't), Roger Wilmut has kindly provided instructions for those who find themselves with this problem.
    Entering iCloud email settings manually in Snow Leopard or Leopard
    Entering iCloud email settings manually in Tiger

  • Why does Firefox on my Windows 7 PC hang (become unresponsive) while it waits for most pages to load or run scripts?

    Firefox hangs (becomes unresponsive) when accessing many sites including Gmail. Eventually, when hung, Firefox will throw up a window saying "WARNING: A script has become unresponsive" or, in the case of Gmail, the page itself will say "Some Gmail features have failed to load due to an internet connectivity problem."
    IE8 and Google Chrome are working normally. I've tried Firefox in safe mode, re-installing and even running Firefox portable from a USB thumb drive. Each time with the same result—Firefox hangs or becomes unresponsive while it waits for most pages to load or run scripts.
    #### PC Workstation Environment ####
    Firefox 13.0.1
    Windows 7
    Symantec Endpoint Protection 11.0.6200.754
    --

    Your problem sounds like the one that a co-worker and I started to have about the same time. Check your Symantec client management control log. You might see a line like the following.
    Date and Time Severity Level Action Test / Production Description API Class Rule Caller Process ID Caller Process Parameter User
    2012-07-30 10:48:09 AM 15 Block Production Unauthorized NT call rejected by protection driver. System Built-in rule 1608 FlashplayerPlu FuncID-B6H, R... None
    At first we thought that it was a Javascript problem until we noticed this log. The key words are 'Block' and 'FlashPlayerPlu'. This problem recently started for us, perhaps with a software push 1-2 weeks ago. Internet Explorer does not hang when accessing pages with Flash.
    The Flash page does eventually load after a long time. However, since the whole browser hangs for a while, for the most part having the Flash plugin enabled makes Firefox unusable if accessing pages with Flash.
    Disabling the Flash plugin solves the hanging problem, but I do not know what is causing the problem, nor do I know when a combination of Windows 7, Flash, and Symantec will work. Your later version of Symantec shows that we might have the problem for a while, but I do not know what customization CSC did with Symantec. My coworker did run a complete virus scan, uncovering nothing. Another co-worker is running Windows XP. She does not have the problem, but I do not know what other versions of software she is running.
    Symantec Endpoint Protection version 11.0.6100.645
    Flash version 11.3.300.268
    Firefox version 14.0.1
    Windows 7 32-bit service pack 1

  • Script Alert "You should only run scripts from a trusted source."

    I created a small javascript which opens Photoshop and resizes some images.
    I want to be able to double-click the .JSX file from Windows Explorer, and have Photoshop execute the script. Likewise, I want to be able to run the .JSX file from the command line.
    The script runs perfectly. However, the problem is that I don't want any user interaction. I want to be able to run the script from the command line without the user having to click anything. What happens now when I try to run the file from Windows Explorer of the command line is, I get a Script Alert with the following text:
    You are about to run a script in Adobe Photoshop CS3. You should only run scripts from a trusted source. Do you want to run the script? Yes/No
    Is there any possible way to bypass this message or to answer in the affirmative?
    Thanks,
    Jamie L.

    Hi... Sorry to revive such an old thread,
        Does anyone know the "trusted source" folder for MAC CS4.
    EDIT!
    My bad.  "The /users/<user_name>/documents/Adobe Scripts" folder is working for this purpose for me.  I needed a path to it and forgot that the ~ resolves to the current user.  Sweet.
    -Bill

  • While running script adstpall.sh , addisctl.sh gives message.

    while running script adstpall.sh , addisctl.sh gives message that
    " OAD is stopped
    OSAGENT is stopped
    LOCATOR is stopped
    Unable to stop gatekeeper. No process id file found.
    session id 20136 is not running
    ......................................

    hi,
    The issue not with /usr/bin/local.  When you excute root.sh, it will try configure the ASM with New GRID HOME. Issue started, whent tried to start
    CRS-4123: Oracle High Availability Services has been started.
    ohasd is starting <<=================================================================
    acfsroot: ACFS-9320: Missing advmutil.
    Please let us know the below details
    ==> Acfs is configured the servers??
         ==>acfsutil registry
                   acfsutil info fs output.
    ==> With out ASM instance , How the database, CRS STarted ???
    ==> Please try stop and start the crs.
    ==> crsctl query crs activeversion output
    Regards
    Krishnan

  • Looking for an SQL query to retreive callvariables + ECC from a RUN SCRIPT RESULT (Translation to VRU)

    Hi Team,
    I am looking for an SQL query to check the data (ECC + CallVariable) received following a RUN SCRIPT RESULT when requesting an external VRU with a Translation Route to VRU with a "Run External Script".
    I believe the data are parsed between the Termination Call Detail + Termination Call Variable .
    If you already have such an SQL query I would very much appreciate to have it.
    Thank you and Regards
    Nick

    Omar,
    with all due respect, shortening a one day's interval might not be an option for a historical report ;-)
    I would recommend to take a look the following SQL query:
    DECLARE @dateFrom DATETIME, @dateTo DATETIME
    SET @dateFrom = '2014-01-24 00:00:00'
    SET @dateTo   = '2014-01-25 00:00:00'
    SELECT
    tcv.DateTime,
    tcd.RecoveryKey,
    tcd.RouterCallKeyDay,
    tcd.RouterCallKey,
    ecv.EnterpriseName AS [ECVEnterpriseName],
    tcv.ArrayIndex,
    tcv.ECCValue
    FROM Termination_Call_Variable tcv
    JOIN
    (SELECT RouterCallKeyDay,RouterCallKey,RecoveryKey FROM Termination_Call_Detail WHERE DateTime > @dateFrom AND DateTime < @dateTo) tcd
    ON tcv.TCDRecoveryKey = tcd.RecoveryKey
    LEFT OUTER JOIN Expanded_Call_Variable ecv ON tcv.ExpandedCallVariableID = ecv.ExpandedCallVariableID
    WHERE tcv.DateTime > @dateFrom AND tcv.DateTime < @dateTo
    With variables, you can parametrize your code (for instance, you could write SET @dateFrom = ? and let the calling application fill in the datetime value in for you).
    Plus joining two large tables with all rows like you did (TCD-TCV) is never a good option.
    Another aspect to consider: all ECC's are actually arrays (always), so it's not good to leave out the index value (tcv.ArrayIndex).
    G.

  • Has the behavior of 'run script' changed in Snow Leopard?

    These work fine:
    tell application "Safari"
    return URL of front document
    end tell
    tell application "Safari"
    set longURL to URL of front document
    return longURL
    end tell
    This does not:
    set getFrontmostURLCommand to "URL of front document"
    tell application "Safari"
    set longURL to run script getFrontmostURLCommand
    end tell
    return longURL
    Why? It looks like a script interpretation error but I can't figure out what's wrong.
    The error returned is:
    error "Safari got an error: Can’t get URL of document 1." number -1728 from "URL of front document"

    I see. Is there a way to make the application variable? I'm writing a function because getFrontmostURLCommand works with a couple of different browsers and I want it to be run conditionally based on the user's browser. Something like this:
    set defaultBrowser to GetDefaultWebBrowser()
    on GetDefaultWebBrowser()
    set _scpt to "export VERSIONERPERL_PREFER_32BIT=yes; " & -
    "perl -MMac::InternetConfig -le " & -
    "'print +(GetICHelper \"http\")[1]'"
    return do shell script _scpt
    end GetDefaultWebBrowser
    on defaultGetFrontmostURLCommand(defaultBrowserApplication)
    tell application defaultBrowserApplication to set longURL to URL of front document
    end defaultGetFrontmostURLCommand
    on caminoGetFrontmostURLCommand()
    tell application "Camino" to set longURL to URL of current tab of browser window 1
    end caminoGetFrontmostURLCommand
    if defaultBrowser is in {"Safari", "WebKit", "Opera"} then
    defaultGetFrontmostURLCommand(defaultBrowser)
    else if defaultBrowser is "Camino" then
    caminoGetFrontmostURLCommand()
    end if
    set the clipboard to longURL

  • Run scripts on a schedule

    Is the a way to run scripts on a schedule? I have a script that I want to run 3 days (Mon, Wed, Fri) a week at a certain time.
    How can I do this

    lets use iCal seeing as it came with your mac.
    create your script and save it where ever you want, open iCal create a new event, on the right hand side you will see the new events draw, set the time you want your script to activate in the from-to area, set it to repeat and end as you wish, go down to alarm and select open file in the drop down, then right below open file their should be another drop down select other from that, that will open a window now select your script, then in the next drop down select on date, your done.
    let me no if you need any more help.
    Budgie

  • Flash restricted running scripts or activeX controls

    Hey, can someone give me a hand?
    I read in a different, older forum, that said to use "<!--
    saved from url=(0014)about:internet -->" but how do i put it
    into my flash projects?
    If this is not what i should use then what should i use to
    remove the sign "flash restricted running scripts or activeX
    controls" that pops up when i run the flash on my website.

    I thought that only happened when running flash
    locally.

  • IE 11 Restricting Running Scripts and ActiveX Controls on Local Files

    I have been coding for my MediaWiki pages and needed to test these pages with IE 11. However, whenever I open a file in IE 11, an annoying message saying "IE 11 Restricted this website from running scripts and ActiveX controls." How do I do a
    one-time fix to stop this from happening in future to local files?

    to test your WEBSITE.... publish it to a web server. eg. localhost/test.local
    web servers and browsers use http(s), not the file: protocol.
    Questions regarding Internet Explorer 8, 9 and 10 and Internet Explorer 11 for the IT Pro Audience. Topics covered are: Installation, Deployment, Configuration, Security, Group Policy, Management questions. If you are a consumer looking for answers or to
    raise a question, it's highly recommended you head on over to http://answers.microsoft.com/en-us
    Rob^_^

Maybe you are looking for

  • File appears different in arrange window and sample editor

    I received a few AIFF files from someone Im working with: 24 bit, 44.1, same as I use. However, although they show up fine in the sample editor, in the arrange window they look clipped, as if they've been recorded too loud. This is making them very h

  • Xserv - user settings are not saved - help!

    I've noticed that user settings do not get saved under OS Xserv... Whenenver I login I get the default dock, with all the admin icons missing! The desktop is saved in the root as /desktop/. (?!?) When the machine was installed the first user was setu

  • Generate TDS certificate for which the spool already exists

    Hi, I have a query. Sometime back I have generated TDS certificate and the same was present in the spool. I did not take any print and it was deleted from spool and no more available. What can I do to generate the same certificate ? If I go for re-pr

  • Add a pin to bitlocker startup

    hi all, I updated my T500 to use Bitlocker with the TPM. Now, to further secure it against brute force password attacks, I want to add a PIN to the startup.  I see that gpedit.msc option to Require additional authentication at startup but I am not su

  • Bean to CFC, Quirky one..

    Well, I'm at my wits end with this one. I've had several people stare at it. I am passing a custom data type (bean) to a function via a webservice to do updating in a database. My invoke statement looks like this. QuoteBean = createObject("component"