Execution Commands

<< Click to Display Table of Contents >>

Navigation:  3. Script Language > Execute-Commands >

Execution Commands

EXE. - Execute-Program

Previous Top Next


MiniRobotLanguage (MRL)

 

EXE. Command

Execute Programm

 

 

Intention

 

Will execute the given program or command-line and return the PID of the started program in #pid#. The system variable #tid# is set to zero.

 

EXE. is optimized for command-lines that need parameters. Place the parameters in P1.

 

If you want to wait until the started process ends, use WPT. - Wait-Process-Termination. with the PID that has been delivered by EXE..

 

' Wait until the started application ends

VAR.$$LNK=?exepath\Sample Apps\TestApp_01.exe

EXE.$$LNK

WPT.#pid#

ENR.

 

 

 

Syntax

 

 

EXE.P1[|P2]

 

 

Parameter Explanation

 

P1 - Filename of program to start

 

P2 - (optional) command-line-parameter to command in P1

 

 

 

Example

 

'***********************************************

' Example 1

'***********************************************

 

EXE.?ws\mspaint.exe|yourpic.bmp

PRT.#pid#--#tid#

MBX.!

END.

'***********************************************

 

'***********************************************

' Example 2

'***********************************************

' Wait until the started application ends

VAR.$$LNK=?exepath\Sample Apps\TestApp_01.exe

EXE.$$LNK|1

WPT.#pid#

ENR.

 

 

 

Remark

 

Technical remark: EXE. uses asynchronous Shell- / Create-Process-Technology and is compatible with other commands that use this technology.

 

If you want to have the Exit-Code of the started application, use EXB. - Execute-Blocking instead.

 

 

 

Limitations:

 

-

 

 

See also:

 

    3.3 Specialfolders

    EXX. - Execute-Extended

    EXH. - Execute-Handle

    EXA. - Execute Asynchron

    EXB. - Execute-Blocking

    EXO. - Execute Open Document

    IEF. / NEF. - If - exist - File

    IEP. / NEP. - If-Exists-Process