SKIP { [n]
| {TO LINE line} }.
1. SKIP [n].
2. SKIP TO LINE line.
Positions the list cursor under the current line or in any other line.
SKIP [n].
This statement positions the list cursor in relation to the current line. The new line is determined by the value of n. For n, a data object of type i is expected. If the value of n is smaller than or equal to 0, the statement is ignored. If n is not specified, the statement is executed as if n contains the value 1.
The cursor is positioned as follows:
Note the following special conditions:
In most application cases, this variant of the statement SKIP
works as if it creates n blank lines. You need to ensure,
however, that these blank lines have no content that can be formatted by the
FORMAT statement. Formattable blank lines can only be generated by the
WRITE statement in combination with SET BLANK LINES ON.
SKIP TO LINE line.
This statement positions the list cursor in the first position of the line on the current page whose
number is determined by the value in line. For
line, a data object of type i is expected.
If the value of line is smaller than or equal to 0, or
larger than the page length defined in sy-linct using
the addition LINE-COUNT
of the program-starting statement, or NEW-PAGE,
the addition TO LINE is ignored and the statement SKIP without additions is executed instead.
If the list cursor is positioned in the first list line using SKIP
TO LINE, and the list has a standard page header, the output in the first line is overwritten
by the standard header. If, however,the cursor is positioned using SKIP
TO LINE in the lines of page headers and page footers that are defined for
TOP-OF-PAGE and END-OF-PAGE, the page headers or footers are overwritten.
The first SKIP statement generates a blank line for the event TOP-OF-PAGE. The second SKIP statement positions the list cursor in this line.
REPORT demo_skip NO STANDARD PAGE HEADING.
DATA sum TYPE i.
TOP-OF-PAGE.
SKIP.
ULINE.
START-OF-SELECTION.
DO 10 TIMES.
WRITE / sy-index.
sum = sum + sy-index.
ENDDO.
SKIP TO LINE 1.
WRITE: 'Numbers with sum' COLOR COL_HEADING,
sum COLOR COL_TOTAL.