Hello,
I am running an applescript from within a perl via Apple’s osascript command line utility, which is nicely bundled into the perl module OSXMacPerl. Anyway, this allows me to plop a blob of applescript code right into my perl script and it is then executed on the fly. Here’s the script:
tell application "FileMaker Pro"
activate
go to window " Title Database"
do script "Automated Export"
go to window "Subjects"
do script "Automated Export"
go to window "Contributors"
do script "Automated Export" end tell (Yes there is supposed to be a whitespace in the title of the first window.)
Pretty simple. It work fine when I run the perl script from an interactive shell or from within BBEdit. However, when I run it as a cronjob, the applescript component fails. Applescript reports the following error: “Application isn’t running.” It then sits there, eating up 77% of the CPU, doing absolutely nothing at all. Filemaker is, of course, running.
Has anyone else tried cronning an applescript? cronning a perlscript containing an applescript? anything even remotely like this?
tia!
Ben