Exec

Top  Previous  Next

 

The Exec command allows you to run any application that can be run from the command line from within the script. Examples of programs that you might want to run include protection software such as .Net Reactor, install builders like InnoSetup, and so on.

lamp IMPORTANT: The function of this command is to run third party applications. As a result if you need support on the syntax required by any application you should contact the support team of the product developer. We are unable to offer support for third party applications of which we have no knowledge and over which we have no control.

Command Syntax

 

Exec:[ExecutablePathAndFileName],[CommandLineArguments]

 

The colon after the command is compulsory. The comma after the executable path is only compulsory where command line arguments are specified. The Exec command itself is not case sensitive, but parameters may be depending on the program, operating system, and locale.

 

Parameters:

 

ExecutablePathAndFileName: The fully qualified path and file name identifying the executable file to be run

CommandLineArguments: Any arguments to the command line that may be required.

 

The ExecutablePathAndFileName parameter is compulsory. The CommandLineArguments parameter may or may not be required depending upon the requirements of the application being run. If any required parameter is missing or invalid an error will be thrown. The parameters must be surrounded by quotation marks if one or more spaces are included. It is good practice to include the quotation marks in any case, so that it reduces the risk of error when writing scripts.

 

Example:

 

Exec:"%%IsccRoot%%\ISCC.exe","%%ScriptRoot%%\myappinstaller.iss"

lamp Note: Because of the function and purpose of the Pipeline Runner, the exec command will not return until the executed program terminates. If you execute a program with a user interface from the script (for example Notepad) the script will not continue to run until you close the program, which may not always be possible if you don't have access to the GUI. If you want to execute a program without monitoring its progress, use the Run command instead.

See Also: Run Conditional DeleteFile MoveFile RenameFile