Pathway/iTS SCREEN COBOL Reference Manual (G06.24+, H06.03+, Pathway/iTS 1.0+)
Procedure Division
Compaq NonStop™ Pathway/iTS SCREEN COBOL Reference Manual—426750-001
6-35
DISPLAY OVERLAY Statement
Using DISPLAY BASE
A running SCREEN COBOL program has at most one current base screen; the current
base screen is defined by the most recently executed DISPLAY BASE statement. The
program can have at most one current overlay screen associated with each of the overlay
areas of the current base screen; the current overlay screen is defined by the most
recently executed DISPLAY OVERLAY statement for each of the areas. With the
exception of the DISPLAY BASE and DISPLAY OVERLAY statements, all screen
operations must deal only with the current screens.
The definition of a screen is local to a SCREEN COBOL program; therefore, a program
cannot use a current screen that was established by another program, even if the
declaration of the current screen is identical to the declaration of the screen in the
currently executing program. Consequently, the program must perform a DISPLAY
BASE operation to use a screen.
If a program has current screens defined and calls another program that has screen
declarations, the current screens become undefined for the first program. If the first
program is to make use of the screens it previously displayed, the first program must
execute DISPLAY BASE/OVERLAY statements after the call to the program has
completed.
If a program calls another program that has no screen declarations or does not exist, the
definitions of the current screens remain unchanged.
When a program that has defined the current screens executes an EXIT PROGRAM
statement, the current screens become undefined. The program must display the screens
again to make use of them even if no intervening screen operations have occurred since
its exit.
DISPLAY OVERLAY Statement
The DISPLAY OVERLAY statement formats the specified overlay screen from the
screen definition in the Screen Section and associates the overlay screen with the
overlay area in the current base screen. The statement also selects the overlay screen
description for subsequent operations, but does not display the screen.
The DISPLAY OVERLAY DYNAMIC statement performs the same function as the
two-statement sequence DISPLAY OVERLAY and DISPLAY. (DISPLAY follows
DISPLAY BASE.)
The DISPLAY OVERLAY statement operates differently for terminals in block mode
from terminals in conversational mode. It cannot be used for communication with
intelligent devices.
For terminals in block mode, DISPLAY OVERLAY formats data for screen literals,
VALUE clauses, null characters, and fill characters, and establishes attributes for screen
fields. The overlay screen replaces any previous screen in the overlay area. DISPLAY
OVERLAY does not transmit current values from Working-Storage items to output
fields of the screen; DISPLAY transmits these values.