ars_ExecuteProcess(ctrl, command, runOption=0)
runOption
|
Explanation |
0 | Wait for process to complete and then returned the process' returnStatus and any output that the process had. |
1 | Don't wait for process to complete. |
returnStatus
and
returnString
or 1
Example:
(($returnCode, $returnString) = ars_ExecuteProcess($ctrl, "/bin/ls -l /")) || die "$ars_errstr";
Or as an equivalent, if your server is running on Windows:
(($returnCode, $returnString) = ars_ExecuteProcess($ctrl, "cmd /c dir")) || die "$ars_errstr";
ars_ExecuteProcess was introduced in version 1.5 of ARSperl.
Last changes to this page 31st March 2009 by michiel.beijen@gmail.com