At 21:13 -0500 7/2/02, Brad Rice wrote:
>How do you call Applescript from Perl? I want to make a CGI that 
>runs an applescript.

In MacPerl, use:

&MacPerl'DoAppleScript(<<"END_SCRIPT");
        tell application "Finder"
                move alias "$folder" to trash
        end tell
END_SCRIPT

I believe MacPerl can also do raw AppleEvents.

In Mac OS X Perl, use /usr/local/bin/osascript, man osascript for 
info on how to use it and send the data to it from the Perl script.

Is there any other ways?

Enjoy,
    Peter.

-- 
<http://www.interarchy.com/>  <ftp://ftp.interarchy.com/interarchy.hqx>

Reply via email to