Description
Forces the program to evaluate the formula while it is printing database record data.
Action
Forces the program to evaluate the formula while it is printing database record data.
Typical uses
Formulas are normally evaluated at the following times:
If no database or group field is included in the formula, the formula is evaluated before the program reads database records.
If a database is included in the formula, the formula is evaluated while the program reads database records.
If a group field, page # field, subtotal, and so on, is included in the formula, the formula is evaluated after database records are read and while the data from the records is being printed in the report.
WhilePrintingRecords forces the formula to be evaluated while the program prints database records.
This function can also force a formula that includes no database fields and no group fields to process while printing records instead of before reading records. It will also force a formula that includes database fields to process while printing records instead of while reading records.
Examples
WhilePrintingRecords;
3* Sum ({file.QTY1}, {file.QTY2})
Forces the formula (which contains a group) to be evaluated at its normal time (while printing records).
WhilePrintingRecords;
ToNumber ("12345")
Forces the formula (which contains no database fields or groups), to be evaluated later than it would normally be evaluated. In this case, it causes the formula to be evaluated while printing records instead of before reading records.
Using this function in a formula forces the formula to be evaluated at print time. For more information on evaluation time considerations, see
Evaluation Time.