Declare statements to be executed at the end of each page

!footnote

Declare statements to be executed at the end of each page


SYNTAX

!footnote {
 statements
}

Declare a block of statements to be executed at the bottom of each page.

The compiler counts the number of print statements in the !footnote section, in order to estimate the number of lines required. The special temp sys.Footlines is initialised to this value, and this number of lines reserved at the bottom of every page. However, since the compiler is unable to follow function and subroutine calls, or to determine whether conditional print statements will be executed, sys.Footlines may be changed at run time by direct assignment.

If the value in sys.Footlines is too small, some footnote lines will be printed on a separate page. If the value in sys.Footlines is too large, some blank lines are left at the bottom of the page.


NOTES

  • Since footnote statements can be invoked at any time, care should be taken that unintentional changes are not made. For example, it is normally wise to ensure that sys.Row is not altered.

  • If a program is terminated with the exit command no footnotes are printed on the last page.

  • If the !footnote section consists of a single statement the braces may be omitted and the statement placed on the same line as the !footnote command.

  • Only one !footnote section may be defined.


EXAMPLE

!footnote {
     print
     print tab(3); "Page: "; sys.PageNumber;
     print tab(55); "Records processed: ";sys.RecordCount
}

RELATED TOPICS

Reports

!final

!heading

!init

!title