This function indicates whether a Windows program previously executed by the function WinExec is still running.

Function Group Execution Windows Embedded Thin Client Mobile Access
WinExecIsRunning Module Activity Synchronous Supported Supported Supported Not supported


Web Studio Help leactivity winexecisrunning.xml d170354e86 WinExecIsRunning

  WinExecIsrunning( numHandle, "optTagReturn" )  
The handle number that was stored in the tag configured in the parameter optStrReturnOrHandle of the function WinExec.
A tag that will receive the completion code returned by the previously executed program.
Note: The tag name should be enclosed in quotes, as shown in the syntax diagram, or else the function will try to use the value of the tag.

Returned value

This function returns the following possible values:
Value Description
1 Program is still running.
0 Execution has been completed successfully (i.e., program has stopped).
-1 Invalid number of parameters.
-2 Invalid handle number. Check the value of numHandle.
-3 Execution has been completed, but the return tag is invalid. Check the value of optTagReturn.


Tag Name Expression
MyTag WinExecIsRunning(numHandle)
MyTag WinExecIsRunning(numHandle,"return")