How to Copy Items w/ Spotlight Comments?

Hi all,
I built my first Automator workflow, but having a slight problem. I'm using the "Ask for Finder Items" action which allows me to browse my image collection. I then use "Review Photos" action to review the photos and I have "Approved images" checked, then finally "Copy Finder Items" action to copy those approved images to a specified folder.
Here's the problem: I have spotlight comments in the original files that aren't being copied with the file to the specified folder. Can anyone write me a workflow that will properly copy files with the comments?
Thanks, Bill

Niel:
OK, I setup the AppleScript action, but now I'm getting an Error dialog that says "Can't set folder "Users:myusername:Desktop:SelectedImages" to {alias "myharddrive:StockPhotos:iStockphoto:iStock_000000446037Medium.jpg"} plus any other images I selected w/ error (-10006)
I thought the problem might have been the spaces in folder names, so I took all spaces out, but to no avail. Any suggestions?
Thanks, Bill

Similar Messages

  • How to copy a files spotlight comments for an entire folder and place them in a different file with that same name

    I have the same question in a different discussion but I already marked it as solved because one of the questions was answered. Here's the linke to the other discussion if your interested https://discussions.apple.com/thread/5970421 
    I have movie covers saved as a jpeg for every movie my family and I own. There is about 700 and they each have a comment of the main actors, release dates, and descriptions. This makes it easy to find what to watch.Is there an applescript, automator, program I can download,  or program code supported in xcode that will do the following set of inscructions?
    Take the name of the picture file and spotlight comment, copy and paste it to a movie file's comments to a file with the same name but obviously has different extention. For an example
    In a Pictures folder
    Name: Dark Knight, The.jpeg       Comment: (2008) Genre: Action...             <- copy comment
    In a Movie Folder
    Name: Dark Knight, The.m4v       Comment:                                               <- paste
    and do this for all 700 files

    Clendenen02 wrote:
    where should I run the code? in the terminal, or an applescript, or should put it in xcode and run it from there or the terminal.
    What MrHoffman said.
    But if it's easier, you can wrap it in Automator and have Automator ask for the Folders: (Test on a sample of your files before running on all 700 files)
    (do you really own 700 movies??)
    The Workflow is:
    Put this in the Run Shell Script Action (and pass input as arguments":
    PicDir=$1
    MovDir=$2
    for f in $PicDir/*
    do
         if [ ! -d "$f" -a "${f##*.}" = "jpeg" ]; then
              comment=$(mdls -raw -name kMDItemFinderComment "$f")
              if [[ $comment != "(null)" ]]; then
                   picname=${f##*/}
                   movname=${picname%.*}.m4v
                   if [[ -e "$MovDir"/$movname ]]; then
    osascript <<-EOF
    tell application "Finder"
    set comment of file (POSIX file "$MovDir/$movname") to  "$comment"
    end tell
    EOF
                   fi
              fi
         fi
    done
    (BTW, I know that this is a bit of sloppy scripting (wraping an osascript in a Bash Script wrapped in Automator, but it does what you need)

  • How do I make disappeared Spotlight Comments Reappear

    My spotlight comments in an entire folder have disappeared. However, the files do show up if I search in spotlight for a word which was in the comments. How do I make the comments reappear?

    Draw the sahpe as a shape, not as pixels by using the proper button on the horizontal tool settings bar for the shape tools.
    Mylenium

  • How to copy item value that contain a single quote(')?

    Hi,
    I have one "Copy" button in a APEX form. When user clicks it, it simply copy the item's values from the form to a new form by using APEX provided function behind the button- "Set these item values with these values". It is simple and works fine in normal cases. However, see, we have a text field called "Product Details", user types in for example "Oracle's new vision". When I click COPY button, APEX try to copy the text in "Product Details" field from this form to a new form but it returns error because of that single quote. Is there any way I can do something to replace that single quote with two single quote like we usually do in PL/SQL in the place "Set these item values with these values" of APEX button? I tried REPLACE(#P66_PRODUCT_DETAILS#., '''', '''''') but not work. I saw someone in the forum meantioned that to use something like "/#P66_PRODUCT_DETAILS#/" to get around. Any one with success?

    Thanks. I think it should work this way. However, our form has about 20 ~30 text fields, I have to create 20~30 hiddle fields to handle the problem because I never know which field could contain a single quote. Ideally, a new version of APEX should have the functionality to deal with the problem when using "set values with those values" method. At least, it should provide some kind of interaction for user to get away from single quote or comma or column etc.
    What I did is to get out of APEX native function and to create a new records in background by PL/SQL using record id that passed in from APEX form. It works perfectly. Although, user can only edit the record after it is created, not as user friendly as "Copy first-look at it-edit it-then create it" I originally planed.
    Thanks for your help,

  • How to copy a files name and spotlight comments to a text file for an entire folder

    I have movie covers saved as a jpeg for every movie my family and I own. There is about 700 and they each have a comment of the main actors, release dates, and descriptions. This makes it easy to find what to watch. I want my parents to have all of this info but they have a windows laptop so the comments don't transfer with the file and can't be searched like you can on a mac. Is there an applescript, automator, program I can download,  or program code supported in xcode that will do at least one of the following things?
    1)Take the name of the picture file and spotlight comment, copy and paste it into a text document like word that looks like this...
    File Name1- Spotlight Comment for file 1
    File Name 2- Spotlight Comment for file 2
    . for all 700 files in a folder
    2) It would be equally helpful if there was something that would take the name of the picture file and spotlight comment, copy and paste it to a movie file's comments with the same name but obviously has different extention. For an example
    In a Pictures folder
    Name: Dark Knight, The.jpeg       Comment: (2008) Genre: Action...             <- copy comment
    In a Movie Folder
    Name: Dark Knight, The.m4v       Comment:                                               <- paste 
    and do this for all 700 files
    3) Is there a free photo program that works on mac and windows that I can put all my movie pictures in and have a description like I did with the comments? It would also need a place that to search the description for keywords. So Basically an itunes for pictures that works on both mac and windows. If so I still need a way to get the spotlight comments to the description.
    4) I feel like this would make things more difficult, but if not I can put all of the .m4v files in itunes so instead of pasting all the comments back into a file in finder paste them in a description in itunes
    5) At the very least a code that I can run one by one for every file that will paste the comments into the same document
    Note: When I say spotlight comments I mean the comment box that is available when you click on get info of a file. The pictures are in the pictures section of finder in a folder called Movie Pictures. The movie files are on an external hard-drive in a file called Movies. Also I am slightly familiar with applescript and automater in that I have used both to create keyboard shortcuts and simple voice commands. I have programmed in c++ and C too. So If you give me a code for applescript I do know what to do with it.
    Thanks to anyone who takes the time to read all of this and extra thanks to anyone who tries to help.

    Clendenen02 wrote:
    2) It would be equally helpful if there was something that would take the name of the picture file and spotlight comment, copy and paste it to a movie file's comments with the same name but obviously has different extention. For an example
    In a Pictures folder
    Name: Dark Knight, The.jpeg       Comment: (2008) Genre: Action...             <- copy comment
    In a Movie Folder
    Name: Dark Knight, The.m4v       Comment:                                               <- paste 
    and do this for all 700 files
    This Bash script will do it.
    Edit "PicDir" and "MovDir" to the location of your Folders
    (Note: The comment is written to the m4v file using xattr, so the Spotlight comment field appears blank in Finder, but the comment metadata is still indexed by Spotlight (If you add a Spotlight comment from Finder, it is stored both as an extended attribute and in a .DS_Store file)
    #!/bin/bash
    PicDir=$HOME/Desktop/Pictures
    MovDir=$HOME/Desktop/Movies
    for f in $PicDir/*
    do
         if [ ! -d "$f" -a "${f##*.}" == "jpeg" ]; then
              comment=$(mdls -raw -name kMDItemFinderComment "$f")
              if [[ $comment != "(null)" ]]; then
                   picname=${f##*/}
                   movname=${picname%.*}.m4v
                   if [ -e "$MovDir"/$movname ]; then
                         xattr -w com.apple.metadata:kMDItemFinderComment "\"$comment\"" "$MovDir"/$movname
                   fi
              fi
         fi
    done

  • Need help modifying Applescript to copy "Spotlight Comments" into file

    Hello all,
    I have a very large batch of images of Leonardo da Vinci's notebooks. I used the "Spotlight Comments" field of each file to save information about the notebook page depicted in each image:
    Well, I had to modify each image in Photoshop and when I saved the files, Photoshop of course didn't retain the Spotlight Comments. Now, before I modified the images, I duplicated the directory, so I have a copy of all of the images that retain their Spotlight Comments field with each image's information. What I want to do is copy the text from the Spotlight Comments field of the original files and either paste this text into the Spotlight Comments field of the modified files (which are in a different directory, but retain the same filenames as the originals), or at least copy the text from the Spotlight Comments field of the original files and paste each block of text into a txt file with a couple of blank lines in between each entry, so that I can manually copy/paste the citations into the modified image's Spotlight Comments fields.
    I successfully used this Applescript:  https://discussions.apple.com/message/6741062#6741062
    to get the Spotlight Comments from the original files, but it displays them one by one in pop-up dialog boxes and because I have almost a thousand images it is extraordinarily wearisome to copy the text from each pop-up, paste it into a text file, make two blank lines, click "OK" in the pop-up to get the next one...
    Can anyone suggest how I can modify the code I have to tell the Finder to copy the contents of each pop-up and paste them into a single text file with a couple of blank lines between each entry?
    I have the barest, most rudimentary knowledge of Applescript, which is why I'm asking if one of the wizards here can help me modify or write an Applescript to do what I need to do.
    Thank you so much!
    BTW, here is the code from the aforementioned discussion that gets the Spotlight Comments from files. I made into an Applescript application using Automator:
    tell application "Finder"
    repeat with tItem in input
    set (comment of tItem) to (text returned) of (display dialog "Spotlight Comment: " default answer (comment of tItem as string))
    end repeat
    end tell

    Hi,
    Evan Izer wrote:
    Now, before I modified the images, I duplicated the directory, so I have a copy of all of the images that retain their Spotlight Comments field with each image's information. What I want to do is copy the text from the Spotlight Comments field of the original files and either paste this text into the Spotlight Comments field of the modified files (which are in a different directory, but retain the same filenames as the originals)
    This script does exactly that:
    set sFolder to (choose folder "Select folder wich contains original images.") as string
    set dFolder to choose folder "Select folder wich contains modified images."
    tell application "Finder"
          repeat with tItem in (get document files of dFolder)
                set origFile to sFolder & (get name of tItem)
                if file origFile exists then
                      set origComment to comment of file origFile
                      set comment of tItem to origComment
                end if
          end repeat
    end tell

  • How to copy List item from one list to another using SPD workflow using HTTP call web service

    Hi,
    How to copy List item from one list to another using SPD workflow using HTTP call web service.
    Both the Lists are in different Web applications.
    Regards, Shreyas R S

    Hi Shreyas,
    From your post, it seems that you are using SharePoint 2013 workflow platform in SPD.
    If that is the case, we can use Call HTTP web service action to get the item data, but we cannot use Call HTTP web service to create a new item in the list in another web application with these data.
    As my test, we would get Unauthorized error when using Call HTTP web service action to create a new item in a list in another web application.
    So I recommend to achieve this goal programmatically.
    More references:
    https://msdn.microsoft.com/en-us/library/office/jj164022.aspx
    https://msdn.microsoft.com/en-us/library/office/dn292552.aspx?f=255&MSPPError=-2147217396
    Thanks,
    Victoria
    TechNet Community Support
    Please remember to mark the replies as answers if they help, and unmark the answers if they provide no help. If you have feedback for TechNet Support, contact
    [email protected]

  • How can I disable spellcheck in "Spotlight Comments" window?

    How can I disable the daft spellchecking in the “Spotlight Comments” section of OS 10.8.3’s “Get Info” windows? I don’t have that problem in my older Mac, which has OS 10.5.8.

    I don't really see it as a march backwards, but then I'm not a great speller or typist so I'm happy to have it check my comments.
    Is there some specific reason you call the service "daft"? I assume you know you can always add words to the spelling dictionary. I have done that for a few made up "words" I use as tags. That way, I know if I have accidentally misspelled them & there is no mystery about why a Spotlight search doesn't include them.
    Would that work for you?

  • Ask for Text for Set Spotlight Comments for Finder Items

    I want the text from the "Ask for Text" to go in to the "Set Spotlight Comments for Finder Items" action, but they don't seem to interact.
    Any ideas?

    first you make a new variable using variables tab. then you add the action "set value of variable" right after the action ask for text. drag the variable you made to the variable field of that action. this will set the value of that variable to the output of the previous action.

  • How to copy Configurator keychain items to user accounts

    I'm managing a lab of iPads in an education environment.  And have set up a "base" image for the iPads under an administrative account with Configurator.  The Macbook is bound to the domain and I can authenticate with a number of users no problem, but if I go to try and manage the iPads, i get a "private/public key" error.
    I've determined that the issue is with the Key items found under the keychain.  If I copy the administrative keychain to the users profile and log in (forcing the login keychain update) it will work fine under the users account.  but this is not something I want to do as it requires me to give out an administrative password. And if I delete the login keychain from the user template, the user generates new keys causing the error above.
    So... does any one have any ideas how to copy keychain items from one user to the template user?

    Move your itunes to library to a centralized folder.  For instance directly on your hard drive.  Then set your itunes library to that folder where all itunes media is kept, or only the items you wish to "share" between user accounts.

  • How to add spotlight comment on more than one file simultaneously?

    Hi
    how can I add spotlight comment on some files in mountain lion ?
    it's very useful and necessary specially when I want to add some comments on many files or photos that newly importet.
    is there any way in OS X  for that?
    Thank you!
    Safa

    Automator workflow of the month: Add Spotlight comments

  • How to Import Spotlight Comments into iPhoto

    Is there a way to import Spotlight Comments into iPhoto at the same time I bring in the image?

    Afraid not. You will need something to convert those comments into standard photo metadata like Exif or IPTC.
    Regards
    TD

  • Saving Spotlight Comments?

    I saved some NBC "Meet the Press" netcasts as QuickTime movies to my hard drive. I want to be able to store comments with each movie as to who the guests and topics are for each show.
    When I copy the information and paste it into the "Spotlight Comments" box of a given movie's "Get Info" window, and then come back to re-open the same window some time later, the information is gone!
    How can I get this kind of metadata tag to stick to a file? Is there another place I should put this information instead?

    Unfortunately the data in the Spotlight Comments field in GetInfo is really stored in the .DS_Store file in the folder the file is in. I think the best idea is to open the movie in QuickTime Player, then go to the menu item Window and select Show Movie Properties. Click the Annotations tab, from the dropdown Add Annotation menulet at the bottom select Comment, and then type in your information and save. This will become part of the metadata of the file and can be searched for with Spotlight.
    Francine
    Francine
    Schwieder

  • Automate Spotlight Comments

    I'm very new to this stuff but I've been messing with an Automator action to tag files with a Spotlight Comment as a Service. I want be able to select a folder and then have it ask me for text which it then saves as a Spotlight comment to all the files I've selected. Seems really easy. But I can't get it to work. I must be missing a step.
    Here's what I have...
    1. Get Folder contents (or I've tried get specific Finder items as a test.)
    2. Ask for Text.
    3. Set Value of Variable (which I've called Tag).
    4. Set Spotlight Comments for Finder Items (with my variable, Tag, dragged into the Text area.)
    I cannot get this to work. I get an error of The action "Set Spotlight Comments for Finder Items" was not supplied with the required data.
    I've also tried inserting a "Get value of variable" after the Set Variable. That doesn't work either. I get an erro of NSCFArray intiWithObjects:count:}: attempt to insert nil object at objects [0].
    One clue would be that when the ask for text dialogue opens, it's already filled in with the pathname of the file.
    I'm sure this is a piece of cake for someone to explain to me as to why it doesn't work.
    Thanks,
    Jeff

    I don't know how to accomplish this in Automator and will be interested in knowing the solution, but in AppleScript you can go about it like this
    1. Get Folder contents (or I've tried get specific Finder items as a test.)
    set aFile to (choose file without invisibles) as alias
    -- Add 'with multiple selections allowed' if you want to do this for multiple files
    --but then the rest of the code has to be changed as well
    2. Ask for Text.
    3. Set Value of Variable (which I've called Tag).
    set theComment to text returned of (display dialog ("Enter comment for" & return & (aFile as string)) default answer "")
    4. Set Spotlight Comments for Finder Items (with my variable, Tag, dragged into the Text area.)
    tell application "Finder" to set comment of aFile to theComment

  • Smart Folders, Spotlight comments and Apple mail messages

    Hi,
    I have a simple question, but couldn't figure it out yet:
    I have a workflow that tags specific mail messages according to the specific mail inbox folders I assign them to (be it via incoming rules, or Act-On rules) by automatically adding specific Spotlight comments.
    My mail messages, therefore, have text in their comment boxes (if you check via GetInfo).
    When I use Spotlight, I can find mail messages by searching for the comments - this is exactly as expected.
    I however also have smart folders (searching for a specific Spotlight comment) that list other files that I tag with the same Spotlight comments - but my Smart Folders never find the mail messages with the requested tags (at most they find the folder that contains the messages if this folder is tagged - which it is generally not).
    Question: how can I make sure that the Smart Folder does indeed identify and list the mail messages that I have tagged via Spotlight comment ?
    Thanks a lot !
    D.V.
    iBook G4   Mac OS X (10.4.6)  

    Howdy,
    I cannot reproduce this problem myself...I see the same results in both the Mail spotlight and the spotlight menu bar item. I'm not sure if after installing 10.5 a new spotlight index is created, but it might be worth a shot to create a fresh index and see if that helps.
    I haven't tried this, but it was the easy way I could find to reindex.
    Open Spotlight Preferences
    In the privacy tab, add the volume you want to reindex
    After a few moments, remove that volume from the privacy list
    Allow Spotlight to reindex the volume
    Please let me know if that works for reindexing.
    +R

Maybe you are looking for