#INCLUDE

Function

Includes an external source file into the Production Reporting report specification.

Syntax

#INCLUDE filename_lit

Arguments

filename_lit

A valid filename for the platform on which this application is compiled.

Description

You may want to keep commonly used routines in a single file and reference or “include” that file in programs that use the routine. For example, you might have a set of #DEFINE commands for different printers to control initialization, font changes, and page size declarations. You can reference the appropriate include file depending on which printer you want to use.

INCLUDE files can be nested up to four levels.

Variable substitution scanning takes place before the #INCLUDE command is processed. This allows you to substitute all or part of the INCLUDE file name at run time, adding flexibility to controlling which file is included for the run.

Examples

#include 'gethours.dat'    ! Common procedure.
#include 'XYZheader.dat'   ! Common report heading for XYZ Company.
#include 'printer{num}.dat'! Include printer definitions for 
                           ! printer {num},which is passed
                           ! on the command line:
                           ! SQR REP1A SAM/JOE 18
                           ! where 18 is the arbitrary
                           ! number assigned your printer
                           ! definition file, 'printer18.dat'.
                           ! The report would contain the
                           ! command:  ASK num
                           ! in the SETUP section, preceding
                           ! this #include statement.