_plength example
This example sets the form length to 10 lines and prints 25 lines of output. Each line simply prints line number and count (1 through 25). A three-line heading prints "Top of Page" on each line 1:
_plength=10
_pageno=1
_plineno=0
set printer on
for i=1 TO 25
if
_plineno=0 // At first line of page
?
?
"Top of Page ",_pageno
?
endif
?
"Line",_plineno,"i=",i
endfor
set printer off
close printer
// The first two pages are:
//
// Top of Page 1
//
// Line 3.00 i= 1
// Line 4.00 i= 2
// Line 5.00 i= 3
// Line 6.00 i= 4
// Line 7.00 i= 5
// Line 8.00 i= 6
// Line 9.00 i= 7
//
// Top of Page 2
//
// Line 3.00 i= 8
// Line 4.00 i= 9
// Line 5.00 i= 10
// Line 6.00 i= 11
// Line 7.00 i= 12
// Line 8.00 i= 13
// Line 9.00 i= 14