Command Launch Launch a Program...

The LaunchExe command enables you to launch a program. You may use it to launch Word or any other application.

When selecting the Launch a Program... menu item, the following dialog

Launch Exe Command Input

will help you specify the Launch command parameters:

filename

Specify the filename of the executable to launch.

commandLine

Specify a command line. It is optional.

waitForTermination

Indicates if the command should wait for the launched program's termination.

Example 1

The following command will launch Notepad for example:

{LaunchExe}
filename = "C:\Windows\notepad.exe"
waitForTermination = "n"
{/LaunchExe}

Example 2

The following command launches the Textware home web page using Firefox:

{LaunchExe}
filename = "C:\Program Files (x86)\Mozilla Firefox\firefox.exe"
commandLine = "https://www.textware.com"
waitForTermination = "n"
{/LaunchExe}

Example 3

The following glossary entry gives an example where the LaunchExe command will wait for the program termination:

{CopySelection}
{LaunchExe}
filename = "D:\TransformClipboardText.exe"
waitForTermination = "y"
{/LaunchExe}
{Paste}

It has three steps:

  1. {CopySelection} copies the selected text to the clipboard.
  2. {LaunchExe} command runs a progam that:
    • reads the text from the clipboard,
    • transforms the text that is read from the clipboard,
    • and finally copies the transformed text, back to the clipboard,
    and waits for it to complete.
  3. and finally {Paste} pastes the text from the clipboard.

In this entry it is essential to wait for the launched program's termination in order to be sure that it has completed its execution, before the Paste command is processed.