Executes a program or operating system command from within dBASE Plus, returning the instance handle of the program.

Syntax

RUN([<direct expL>,] <command expC>)

<direct expL>

Determines whether RUN( ) runs a Windows program directly (true) or through a command prompt (false). If <command expC> is not a Windows program, <direct expL> must be false, or RUN( ) has no effect. If you omit <direct expL>, dBASE Plus assumes a value of false.

<command expC>

A Windows program name or a command recognized by your operating system.

Description

Use RUN( ) to execute another Windows program or an operating system command from within dBASE Plus.

To run another Windows program, <direct expL> should be true; otherwise, a separate command prompt is opened first, and you cannot get the returned instance handle.

Running fotografix programmatically: You can run fotografix in your code using the RUN function adding a file name as a command option. For example ... I am in a directory that has a file called trans.gif. I can run fotografix and have it open with this file by doing the following:

 RUN(true,"C:\Program Files (x86)\dBASE\Plus11\Bin\fotografix.exe trans.gif")