- In layout editor, select the report element that you want to conditionally format.
- Choose Highlights on Property Editor.
The Highlights page appears. It is empty if you have not yet specified any formatting rules for the selected element.
- Choose Add to add a new formatting rule.
New Highlight appears. It prompts you to specify the condition, or rule, for applying a particular format to the report element.
- Create the rule for applying a particular format to the report element by completing the following steps:
- Think of the rule in plain English first. For example:
There are two parts to the rule: If and Then.
The New Highlight dialog helps you specify the If and Then parts of the rule by breaking them down to more specific parts.
- Specify the If part of the rule by completing the following steps:
- In the first field, specify the first part of the If expression. Using the example rule, this is order total.
- If the order total values come directly from the selected element, choose "Value of this data item" from the drop-down list.
- If the order total values come from another element, specify the name of the field or an expression if the values are calculated. The following expressions are two such examples:
If you want help constructing the expression, use Expression Builder by choosing the ellipsis (...) button.
- In the second field, specify the second part of the If expression by selecting an option from the list. Using our example rule, this is "Larger than."
- In the third field, specify the third part of the If expression. Using our example rule, this is a value of 50000.
You completed the If part of the rule, which specifies:
- Specify the Then part of your rule, which is "then set the font color to blue and the font style to bold," by completing the following steps:
- Choose Color, then select a color from the color picker.
- Choose B to select the Bold format.
Choose OK.
The formatting rule you just created appears in the Highlight list. The rule takes effect the next time you run the report.
- Preview the report to test your formatting rule.