NEW-PAGE
Syntax
NEW-PAGE [erase_from_line_num_lit|_var|_col]
Description
Writes the current page and begins a new one.
For line printers, this command can optionally erase the old page starting at a specified line. After this action is performed, the location on the page is unchanged—that is, the value of #current-line is the same. The default action is to erase the entire page and reset #current-line to its initial value for the page.
In reports in which an overflow page is needed, sometimes retaining information from the first page on succeeding pages is useful.
Each NEW-PAGE occurrence adds a form feed character to the output file unless you specify FORMFEED=NO in the DECLARE-LAYOUT for this program in the SETUP section.
Note:
A NEW-PAGE automatically occurs if page overflow is detected. Tabular reports do not require explicit NEW-PAGE commands; use NEXT-LISTING instead.
Parameters
| Parameter | Description |
|---|---|
|
erase_from_line_num_lit | _var | _col |
Specifies a numeric column, variable, or literal for line printers. |
Example
The following example illustrates the NEW-PAGE command:
! Write current page, then erase it
! beginning at line 5.
new-page 5