Turn STATEMENT

PURPOSE:  The TURN statement enables or disables the reporting options HEADINGS, PAGING, and FILL.

SYNTAX

TURN [ON n] {HEADINGS {ON; OFF}; PAGING {ON; OFF}; FILL {ON; OFF}} [HUSH]

[IF; UNLESS clause] [iterate clause]

n

is a number or declared field that gives the number of the report to which the statement applies.

HEADINGS OFF

tells ACCENT R not to print the HEADINGS section at the top of the page.  The default status is ON.

PAGING OFF

tells ACCENT R to cancel the automatic paging.  The default status is ON.

FILL OFF

tells ACCENT R not to fill the last page of the report with blank lines.  The default status is ON.

Example

These statements prevents headings from being printed on even numbered pages for report 5.

TURN ON 5 HEADING ON
TURN ON 5 HEADINGS OFF IF @PAGE(5) MOD 2 = 0

NOTES:  TURN…ON would normally be used only to cancel a previously given TURN…OFF statement.

TURN PAGING OFF is useful if generating a formatted data table with REPORT.  When this statement is in effect, ACCENT R ignores @LINES and does not increment @PAGE.  TURN PAGING OFF instructs ACCENT R to print the HEADINGS section only once, at the beginning of the report; the FOOTINGS section  will not print at all.  However, the SKIP  statement will still execute.

It is possible, by turning off all three options, to create a report that could be used as a DS.  This option is valuable if filling a DS using features that are not normally available when creating a DS.  Such features include:  inter-record functions, picture formats, or validation across fields in a record (e.g., IF FLDA = 2 * FLDB).