Crystal Reports  

General Purpose Conditional Formatting Functions (Basic Syntax)

There are three general purpose conditional formatting functions:

These functions are displayed at the top of the Functions tree whenever appropriate. See Formula Editor Dialog Box.

DefaultAttribute can be used for any formatting formula, CurrentFieldValue for any formatting formula where you are formatting a field value, and GridRowColumnValue for any formatting formula where you are formatting a field value in a Cross-Tab or OLAP grid.

CurrentFieldValue enables you to conditionally format Cross-Tab or OLAP grid cells based on their value. GridRowColumnValue enables you to conditionally format the cells of a Cross-Tab or OLAP grid based on row or column headings values. These two functions are essential in some situations as there is no other way in the formula language to refer to these fields.

Example

If you wanted Cross-Tab cells to be suppressed if the values are less than 50,000:

Rem Conditional formatting example 4
formula = CurrentFieldValue < 50000

See Also

Performing Report Calculations