Hi I am a beginner in Macperl. My project now is to run an application from a cgi-script, my problem is when I am running the application in the script the script stops before the application is finish Have try with the commant 'wait' but macperl doesn't accept I am very glad if someone can help me The script is below Regards \Claes #!perl print "Content-type: text/html\n\n"; $test='HD850:Pub:test2.sps'; $out='HD850:Pub:test2.sps Output'; Get the input read(STDIN, $buffer, $ENV{'CONTENT_LENGTH'}); Split the name-value pairs @pairs = split(/&/, $buffer); foreach $pair (@pairs) { ($name, $value) = split(/=/, $pair); $value =~ tr/+/ /; $value =~ s/%([a-fA-F0-9][a-fA-F0-9])/pack("C", hex($1))/eg; $FORM{$name} = $value; } $synt=$FORM{'synta'}; open(SYNTAX,">$test"); print SYNTAX "$synt"; close(SYNTAX); MacPerl::DoAppleScript(<<END_SCRIPT); tell application "Finder" activate select file "test2.sps" of folder "Pub" of startup disk open selection using file "SPSS Production Mode" of folder "SPSS 6.1" of folder "Program" of startup disk end tell END_SCRIPT open(INPUT,"$out") || die "error in perl"; print "<html><title>SPSS Results</title>\n"; print "<pre>\n"; print <INPUT>; print "</pre></html>\n"; close(INPUT); -------------------------------------------------- Claes Bjšrklund http://www.canit.se/~claes claes@canit.se finger claes@uno.canit.se -------------------------------------------------- ***** Want to unsubscribe from this list? ***** Send mail with body "unsubscribe" to mac-perl-request@iis.ee.ethz.ch