HEADING |
![]() ![]() ![]() |
The HEADING statement defines text to be printed or displayed at the top of each page of output.
Format
HEADING {NO.EJECT} {ON print.unit} text
where
The HEADING statement defines the text of a page heading and, optionally, control information determining the manner in which the text is output. A page heading is output whenever the first line of output on a page is about to be printed or displayed. The HEADING statement normally causes subsequent output to appear on a new page. The NO.EJECT option defers the new heading until the start of the next page.
The heading text may include the following control tokens enclosed in single quotes. Multiple tokens may appear within a single set of quotes.
When a heading line uses both G and C, the heading is considered as a number of elements separated by the G control options. The element that contains the C option will be centered. The items either side of the centered element are processed separately when calculating the number of spaces to be substituted for each G option.
Unrecognised control tokens are ignored. A quotation mark may be inserted in the printed text by using two adjacent quotation marks in the text string.
There is no limit to the length of a heading text. Each line will be truncated at the width of the print unit. The effect of using a heading which does not leave sufficient space for at least one line of text is undefined.
|