RunHideWait

Runs a program as a hidden window, and waits for it to close.

Syntax:

RunHideWait (program-name, parameters)

Parameters:

(s) program-name the name of the desired .EXE, .COM, .PIF, .BAT, .CMD file or a data file.

(s) parameters optional parameters as required by the application.

Returns:

(i) @TRUE if the program was found; @FALSE if it wasn't.

 

Use this command to run an application as a hidden window. The WIL program will suspend processing until the application is closed.

If the drive and path are not part of the program name, the current directory will be examined first, followed by the Windows and Windows System directories, and then the DOS path will be searched to find the desired executable file.

If the "program-name" has an extension other than .EXE, .COM, .PIF, .BAT or .CMD, it will be run with the associated application.

Note: When this command launches an application, it merely informs it that you want it to run as a hidden window. Whether or not the application honors your wish is beyond RunHideWait's control.

Example:

RunHideWait(Environment("COMSPEC"), "/c dir *.exe> temp.txt")
Print("temp.txt","",@NORMAL,0)

See Also:

RunShell, RunHide, RunIconWait, RunWait, RunZoomWait, RunWithLogon, ShellExecute WinWaitClose