Output Window

This document covers the following topics:

About the Output Window

In the local environment, an output window appears when a Natural program writes output to the screen. Example:

Output window

In a remote development environment, a terminal emulation window or a Natural Web I/O Interface client appears instead of an output window. See Terminal Emulation and Natural Web I/O Interface Client in the Remote Development Using SPoD documentation.

Working in the Output Window

A button for the output window is shown in the Windows taskbar; keep this in mind when you minimize the output window.

The output window can be resized and moved. If the output window is smaller than the Natural output page, scroll bars appear.

PF keys defined in a Natural program are converted to command buttons. You can either use these command buttons or the PF keys on your keyboard.

Information from an input field in the Natural output can be cut or copied to the Windows clipboard, and information from the Windows clipboard can be pasted into an input field of the output window.

The cursor can be positioned using the mouse. Double-clicking the left mouse button simulates the ENTER key. The system variables *CURSOR, *CURS-COL and *CURS-LINE are always set to the current mouse position.

Windows created using the statement DEFINE WINDOW or the terminal command %W are placed into the output window. They are moveable, sizeable, and scrollable child windows of the output window.

The output window is automatically closed when the program terminates. It cannot be closed manually using the standard Windows close button. If you want to close the output window before the regular termination of the program, you can press ESC (provided that this feature has not been disabled; see below).

Changing the Output Window Profile

Several options can be set for the output window. These options can either be set directly in the output window (as described below) or in Natural Studio (see Setting the Options in the documentation Using Natural Studio).

Start of instruction setTo change the output window profile

  1. From the control menu of the output window, choose Profile.

    This command is not available when the display of the profile dialog has been disabled. In this case, the output window options can only be set in Natural Studio.

    The following dialog box appears.

    Output window profile

    This dialog box contains the same options as the Options dialog box of Natural Studio. There is one exception: the following command is only available in the above dialog box since it can only be specified for a running application:

    Save current size and position

    When this check box is selected, the current size and position of the output window is saved.

  2. Set all required options. For a detailed description of each option, see Output Window Options in the documentation Using Natural Studio.

  3. Choose the Save button to save your changes permanently.

    Choose the OK button to save your changes for the current session only.

Using Your Own Icon for the Output Window

Instead of using the Natural icon for the output window, you can use your icon. This icon will be shown in the control menu of the output window and in the Windows taskbar.

Start of instruction setTo use your own icon

  1. Create an icon file (*.ico).

  2. Store your icon file in a directory where it can be found by Natural.

    Natural tries to find the icon file first in the RES subdirectory of the logon library, then in the RES subdirectory of each steplib and then in the directory assigned to the Windows environment variable NATGUI_BMP.

  3. To use your own icon file, use the following statement in your program:

    SET CONTROL 'I=icon-file-name.ICO'

    See also the description of the terminal command %I.