Compaq COBOL AAQ2G1FTK User Manual

Page 393

Advertising
background image

Using ACCEPT and DISPLAY Statements for Input/Output and Video Forms

11.1 Using ACCEPT and DISPLAY for I/O

The following example illustrates the UPON phrase used in conjunction with
DISPLAY:

SPECIAL-NAMES.

LINE-PRINTER IS ERROR-LOG
.
.
.

PROCEDURE DIVISION.

.
.
.
DISPLAY ERROR-COUNT, "

phase 2 errors, ", ERROR-MSG UPON ERROR-LOG.

11.2 Designing Video Forms with ACCEPT and DISPLAY Statement

Extensions

The extended Compaq COBOL options to the ACCEPT and DISPLAY statements
provide video forms features. You can develop video forms on VT100 and later
series terminals and faithful emulators and write your application without regard
to the type of terminal on which the application will eventually run. You can also
run your forms application in the terminal emulator window of a workstation.

1

Using the extended forms of the ACCEPT and DISPLAY statements, you can
design video forms to:

Make data entry applications, menu selections, and special control keys easier
to use.

Clarify the input expected from an operator.

Improve the appearance of an application’s terminal dialog.

Figure 11–1 is a sample form created by a Compaq COBOL program. It is for
entry of employee information into a master file. This program prompts the user
to type in data. Then the program writes it to the master file and displays a new
form.

Note

The final appearance of screens depends upon the setting of your system
display setup properties (for example, dark on light, or light on dark).
The following figures are representative only.

For information on differences between the Compaq COBOL and the Compaq
COBOL for OpenVMS VAX implementations of screen management, see
Appendix B. For complete reference information on the ACCEPT and DISPLAY
statements, including syntax, see the Compaq COBOL Reference Manual.

1

Compaq COBOL does not provide mouse or split screen support.

Using ACCEPT and DISPLAY Statements for Input/Output and Video Forms 11–3

Advertising