HP 3000 Manuals

DISPLAY Command [ HP ALLBASE/4GL Developer Reference Manual Vol. 2 ] MPE/iX 5.0 Documentation


HP ALLBASE/4GL Developer Reference Manual Vol. 2

DISPLAY Command 

The DISPLAY command displays data on the current screen at a nominated
line within its defined scroll area.

Formats 

DISPLAY {*RESET = line_number} [n] data_ref [n][data_ref]...
        {*RESET = S          }

Parameters 

line_number 

The absolute screen line number where the display line is to be placed.
It may be one of the following:

   *   Whole number.

   *   Numeric constant.

   *   Variable or calculated item.

   *   Screen field name.

   *   Scratch-pad field name.

   *   File record field reference.

   *   Work area field reference.

data_ref 

The item or items to be displayed, each of which may be one of the
following:

   *   A number (representing a number of spaces).

   *   A literal.

   *   A master title name.

   *   A numeric or alphanumeric constant.

   *   A variable or calculated item.

   *   A screen field reference.

   *   A scratch-pad field reference.

   *   A file record field reference.

   *   A work area field reference.

   *   A communication area field.

n 

A number representing the number of spaces to be inserted between the
items when they are displayed.

Description 

The DISPLAY command displays information in the scroll area of the
current screen on a specified line.

The data references define the items to be displayed.  You must specify
at least one item.

HP ALLBASE/4GL displays each item next to the preceding item.  To insert
blank spaces into the display line between items, enter a digit that
corresponds to the number of spaces required between each data reference.
Refer to example 1.

You can express the screen line where the display occurs as either the
letter S, or screen_line_number as defined above.  The letter S indicates
that display starts on the first line of the scroll area.  The first line
of the scroll area is either the top line of the scroll area or the
bottom line of the scroll area, depending on the scrolling direction
defined for the screen.

If you specify a screen line number, it must be within the scroll area
defined for the current screen.  If the screen_line_number is outside the
scroll area, the display occurs on the first scroll line automatically.

With the *RESET = S format of the command, HP ALLBASE/4GL clears the
entire scroll area and displays the item(s) on the first line of the
scroll area.

With the *RESET = screen_line_number format of the command, HP
ALLBASE/4GL clears the specified line and all lines below this line in
the scroll area for a downwards scroll area.  For an upwards scroll area,
the system clears the specified line and all lines above it in the scroll
area.  HP ALLBASE/4GL then displays the item(s) on the specified screen
line in the scroll area.

If the resulting display line is too long to fit on the screen, HP
ALLBASE/4GL truncates the line to fit.

Example 1 

     DISPLAY *RESET=S F-emp_no.emp 2 F-name.emp 2 "Added"

This command displays the fields emp_no and name from file emp on the
first line of the scroll area.  Two blank spaces are left between the
fields.  The word added is also displayed after name.  HP ALLBASE/4GL
clears the scroll area before it displays this information.

Example 2 

     DISPLAY *RESET=V-line *S01 1 *S02 1 *S05 1 *S06[1,3]

This command displays the screen field numbers 1, 2, 5 and the first 3
characters of field 6 on the screen line defined by the contents of the
variable line.  One space is left between each field.

Example 3 

     DISPLAY *RESET=S ""

This command clears the scroll area on the current screen.



MPE/iX 5.0 Documentation