Use this record-level keyword to specify that the record format that you are defining should appear on the display without the entire display being deleted first.
This keyword has no parameters.
REC1 (lines 1 and 2)
REC2 (lines 3 and 4)
REC3 (line 5)
REC4 (line 9)
REC1 (lines 1 and 2)
REC5 (lines 4 and 5)
REC4 (line 9)
If the record with the OVERLAY keyword in effect is already on the display and PUTOVR, PUTRETAIN, or CLRL keyword is not specified, it is deleted and rewritten as a new record.
When the beginning attribute character of a record overlaps the ending attribute character of a record already displayed, the attribute characters overlap each other in position 1 of a line. (The last field of the first record displayed ends in the farthest right display position of the preceding line.)
REC1 (lines 1 and 2)
REC2 (line3)
REC5 (lines 4 and 5)
REC9 (line 9)
The display is always deleted on the first output operation after the file is opened, except when both ASSUME and OVERLAY are specified.
OVERLAY is assumed by the i5/OS™ operating system for ERRMSG, ERRMSGID, PUTOVR, and CLRL functions.
If OVERLAY is conditioned and not selected, then the ERASE, ERASEINP, MDTOFF, PROTECT, and PUTRETAIN keywords cannot take effect if they are selected, unless the PUTOVR keyword is selected. In such cases, the ERASE, ERASEINP, and MDTOFF keywords can take effect.
If you specify OVERLAY, you should also specify the RSTDSP(*YES) keyword on the CRTDSPF (Create Display File) or CHGDSPF (Change Display File) command. Otherwise, data on the display can be lost if the file is suspended.
To delete any of the records on the display, use the ERASE keyword to specify the names of the record formats to be deleted.
If you also specify the CLRL keyword, processing proceeds according to the CLRL specification, not the OVERLAY specification.
A warning message is sent at file creation time if the OVERLAY keyword is specified on a record with the DSPMOD keyword. At run time, the OVERLAY keyword is ignored when the display mode changes.
Option indicators are valid for this keyword.
The following example shows how to specify the OVERLAY keyword.
|...+....1....+....2....+....3....+....4....+....5....+....6....+....7....+....8 00021A R RECL OVERLAY A