English 中文(简体)
Crystal Reports Tutorial

Selected Reading

Crystal Reports - Conditional Formatting
  • 时间:2025-01-05

Crystal Reports - Conditional Formatting


Previous Page Next Page  

To write a conditional formatting formula, right-cpck the report and cpck Format Result Object element → select the property on which you want to apply conditional formula → cpck and it will open formula workshop.

Write the formula in the formula text pane, save and close it.

Conditional Formatting

In this example, if you can print Total Price greater than 60000 in Green and below 60000 in Red, this can be passed in formula workshop.

Formula Example

Formula Example2

In this example, crGreen, crRed, crBlack is used. You can also use actual numeric value of color constants.

There are three common conditional formatting functions −

    CurrentObjectValue

    DefaultAttribute

    GridRowColumnValue

DefaultAttribute can be used for any formatting formula, CurrentObjectValue for any formatting formula where you are formatting an object value, and GridRowColumnValue can be used for any formatting formula where you are formatting an object value in a Cross-Tab.

Advertisements