Previous Next

Formatting Rules:
Hiding or Showing a Field Based on Data Values
This advanced option is used when you want to control the display of data based on the value of the data. For example, if the value of the data to be displayed in a field is null, you may wish to suppress it. There are many other formatting rules that can be applied based on the value contained in the data. For more information, see the Report Designer User Guide (Developer Express), located in the folder where you installed the Report Manager.
In this section, we are going to illustrate formatting rules using an example of hiding/showing a table cell control based on a data value.
To hide or show a field based on data values
1.
2.
To edit the existing layout, click the Layout button, then click the Edit this layout in the layout designer button.
For more information, see Changing the Layout.
3.
4.
5.
6.
Click Edit Rule Sheet to create a new rule.
7.
8.
9.
There are multiple expressions that can be created. For setting a condition on a data value, select the data field from the list, select operator and value to be compared.
Example: [Domain Name (Domain)] == ‘ABC’
10.
Click OK to save the condition.
11.
To show the table cell based on the condition, set the Formatting | Visible behavior to Yes.
– OR – 
To hide the table cell based on the condition, set the Formatting | Visible behavior to No.
12.
Click Close.
13.
To apply this formatting rule to the table cell, click the rule and click the > icon to add the rule to the list for “Rules Applied to This Control”.
14.
Click OK.