Submit Hint Search The Forums LinksStatsPollsHeadlinesRSS
14,000 hints and counting!

10.4: Call Automator Workflows from AppleScript Apps
Tiger only hintIf you need to execute an Automator workflow from an AppleScript, have the application "Atomator Launcher" open the saved workflow document.

A sample code snippet would look something like this:
tell application "Automator Launcher"
   open "... path to saved workflow document ..."
end tell
The workflow will execute without opening Automator, and you get the workflow status in the menu bar. As far as I can tell, the "Automator Launcher" is a core application that does not appear to be scriptable. It won't even show up on a Finder level search.
    •    
  • Currently 1.33 / 5
  • 1
  • 2
  • 3
  • 4
  • 5
  (3 votes cast)
 
[15,080 views]  

10.4: Call Automator Workflows from AppleScript | 7 comments | Create New Account
Click here to return to the '10.4: Call Automator Workflows from AppleScript' hint
The following comments are owned by whoever posted them. This site is not responsible for what they say.
10.4: Call Automator Workflows from Applescript
Authored by: valx on May 23, '05 02:06:50PM

Thanks for the tip! I was wondering why Apple didn't make some type of system wide mechansim for launching Automator actions (like the scripts menu). Now we can launch Automator actions anywhere we can launch scripts . . . cool. :-)



[ Reply to This | # ]
10.4: Call Automator Workflows from Applescript
Authored by: newillmeister on May 23, '05 03:20:30PM

Not quite about this hint (which is cool by the way), but you can save your workflows as 'plug-ins' that can be run from the contextual menu. So while not quite like the AppleScript menu, it works just as well in my opinion.



[ Reply to This | # ]
10.4: Call Automator Workflows from Applescript
Authored by: valx on May 23, '05 09:30:24PM

I had played with the save as plug-in feature before, but I saw it was limited to only 4 or 5 applications. I just went back and looked and realized one of the applications is the script menu. So yes, you can make an Automator action available system wide from the scripts menu without calling it in an AppleScript. However, I launch most of my actions via LaunchBar and it won't run worklows, but it will run AppleScripts. Looks like I'll be able to run Automator workflows via LaunchBar using AppleScript. :-)



[ Reply to This | # ]
10.4: Call Automator Workflows from Applescript
Authored by: TomP on May 23, '05 10:16:28PM
You can put Automator workflows in the systemwide Script menu. Have you tried it? I believe they need to be saved as workflows for this (rather than as applications or plugins); that's what's worked for me, in any case.

[ Reply to This | # ]
10.4: Call Automator Workflows from Applescript
Authored by: Ross L on May 23, '05 06:28:03PM

The reason it doesn't show up in a search is that it is in the System folder. It is in /System/Library/CoreServices/Automator Launcher.app if you must know.

By the way, how can you script it if it's not scriptable?



[ Reply to This | # ]
10.4: Call Automator Workflows from Applescript
Authored by: dpouliot on Nov 23, '07 03:58:34PM

this no longer works under Leopard 10.5.1



[ Reply to This | # ]
10.4: Call Automator Workflows from Applescript
Authored by: dpouliot on Nov 23, '07 06:13:18PM

I figured out how to do it in Leopard:
save the workflow as an application, then execute it this way:
set lf to path to library folder from user domain
tell application "Finder" to open (alias (lf & "Scripts:foo.app:" as text))



[ Reply to This | # ]