| AppCtrlScript | |
| Help |
|
Applies to |
AppCtrlScript (Module: wmACScr1.dll) |
|
Group |
Execution |
|
See also |
SHELLASYNC, SHELLSYNC, CMDASYNC, CMDSYNC, RUNASYNC, RUNSYNC |
This command executes the given commandline (launches a new process).
Depending on the appropriate parameter it is a synchroneous program call OR an asynchroneous program call
Important note on synchroneous calls: If the called program ends up in an infinite loop, pops up with a messagebox or does remain in memory after finished (because of an error), your script will not be continued until the called process finishes anyhow or is killed by the user.
EXECSHELL <Commandline>[, <DefaultDirectory>][, <ShowWindow>][, <Wait>]
[, <WaitTimeOut>][, <KillOnTimeOut>][, <DoEvents>][, <ResultVariable>]
|
Part |
Description | |
| <Commandline> | Complete commandline. If the executable contains spaces in filename then you have to enclose the filename in quotation marks ("). If you hardcode the commandline in script code you have to escape them by writing double quotation marks (""). | |
| <DefaultDirectory> | Default folder to change to for the launched program. | |
| <ShowWindow> |
0|1|2|3; if 0 any window display will be avoided, if 1 then window will be displayed in normal size if any is opened by the application. 2 means window is displayed minimized and 3 means to display window maximized. 1 is the default. | |
| <Wait> |
0|1; if 0 execution is asynchroneously (no wait for program termination), if 1 then execution is synchroneously (processing of the next line in script continues after program termination of the called application). The default is 0. | |
| <WaitTimeOut> |
A time specification of the form "hh:mm:ss". If specified and <Wait>=1 then processing with the next line will be either continued if the specified timeout has been reached (and not only if the program terminates). Only applies if <Wait> is 1. | |
| <KillOnTimeOut> |
0|1; if a timeout is reached a 1 here causes the previously launched process to be killed otherwise script execution continues leaving the launched process up to itself. The default is 0. Only applies if <Wait> is 1. | |
| <DoEvents> |
0|1; if 0 the process is started full blocking the calling application (but leaving a few more processing time to the application) otherwise if 1 events for the calling application are still processed. The default is 1. | |
| <ResultVariable> |
Variable name where to store the result of the operation. Can be "OK", "ERROR" or "TIMEOUT". If not specified the result is forgotten. | |
|
| ||
Synonyms for EXECSHELL are: SHELLEXEC, RUNSHELL
EXECSHELL "c:\winnt\notepad.exe ""f:\poll\Test.txt""","",1,1,"00:00:50",0,1,Result