I'm trying to create a simple Automator workflow that will prompt me for where to move and rename a PDF when I download one from the web. I want to use this for downloading my monthly financial statements.
I'm getting stuck at what I thought would be a simple problem: passing the name of the new file(s) from the Folder Action into the Automator workflow.
How is this done? I tried the "Get Specified Finder Items" action, disabling its input, and passed that to "Set Value of Variable" and in turn to "Ask for Conformation" so I could display the name of the file. It seems whatever I try, I cannot find how to pass the name of the newly downloaded files to the Automator workflow.
This seems like it should be simple. Does someone have an example of an Automator workflow triggered by a Folder Action that passes the files into the workflow?
For the life of me, I can never understand Automator. However I believe I can help in this case. The action you are looking for is called "Get Selected Finder Items" -- it is not intuitive, blame Apple for that.
To test out, I created a folder called "automator_action", then I started Automator (in Snow Leopard) and chose "Folder Action". This is the step you will need to figure out if you are using Leopard or earlier OS.
Next, I drag the "Get Selected Finder Items" (under Finder) over to the right pane, then I dragged the "Rename Finder Items" over and customized it. Finally, I saved the action and ready to test it out. You can see the picture presentation of my "script" here: http://farm3.static.flickr.com/2590/3937364947_33b1a3ab45_o.png
I tested out the action by dragging a file into this folder and sure enough, the action renames it the way I intended. Dragging multiple files also works. Good luck.