Current Help System: Tutor Translator (View Core Help)

### Exec Function

The EXEC command modes are partially supported by PC-DMIS. The Tutor mode value is composed of the application execution mode and window mode.

The Application Execution Modes are:

- 0 (EXEC_NORMAL) starts the application and the part program continues with the execution

- 1 (EXEC_WAIT) starts the application and the part program waits until the application terminates execution before continuing.

- 16 (EXEC_NORMAL_ONCE) checks that the application is not active and then starts the application in EXEC_NORMAL mode (if the application is active, the command is ignored).

- 17 (EXEC_WAIT_ONCE) checks that the application is not active and then starts the application in EXEC_WAIT mode (if the application is active, the command is ignored)

The Application Window Modes are:

- 0 (DEFAULT) opens the window with the default format and position for the application.

- 256 (EXEC_SHOW_NORMAL) opens the window with the format and position the application had the last time it was started

- 512 (EXEC_SHOW_NORMAL_NA) opens the window with the format and position the application had the last time it was started, but the window that was open before the application was started remains active.

- 768 (EXEC_SHOW_ICONIZED) starts the application with the window reduced to an icon.

- 1024 (EXEC_SHOW_ICON_NA) starts the application with the window reduced to an icon, while the window that was active before the application was started remains active.

- 1280 (EXEC_SHOW_MAXIMIZED) starts the application with the window enlarged to fill the entire screen.

PC-DMIS supports only the following execution modes:

- EXEC_NORMAL è NO_DISPLAY , NO_WAIT

- EXEC_WAIT è NO_DISPLAY , WAIT

MODE = 0

EXEC(”NOTEPAD.EXE”, MODE, ”FILETOEDIT.TXT”); translates to è

ASSIGN/MODE=0
IF/MODE%265 == 1
EXTERNALCOMMAND/NO_DISPLAY, WAIT ; C:\WINNT\SYSTEM32\NOTEPAD.EXE C:\WINNT\WTUTOR.INI
END_IF/

ELSE/
EXTERNALCOMMAND/DISPLAY,NO_WAIT ; C:\WINNT\SYSTEM32\NOTEPAD.EXE C:\WINNT\WTUTOR.INI
END_ELSE/