The Conditional Formatting Rules Manager provides the capability to view and edit all conditional formatting rules currently applied to the grid's view, as well as create new ones. The manager is available both at design time and runtime.
Click the Manage Rules item in the Conditional Formatting Menu to invoke the manager.
Set the TableView.AllowConditionalFormattingManager (or TreeListView.AllowConditionalFormattingManager) property to true to enable the manager at runtime.
Specify the type of records contained in the data source using the DataControlBase.DesignTimeDataObjectType property to make the manager correctly work at design time.
This topic consists of the following sections:
The image below shows the conditional formatting rules manager.
The conditional formatting rules manager provides the following actions:
Use the conditional formatting rules manager to apply the following predefined rule types:
Use the Format Cells dialog to define the applied rule's visual style.
Format all cells based on their values
Allows you to apply conditional formatting rules to cells based on their values. You can use the following format styles:
Format only cells that contain
Allows formatting cells comparing cell values with static values. Rules are based on the following types of cell content:
Format only top or bottom ranked values
Allows formatting top or bottom ranked values.
Format only values that are above or below average
Allows formatting values that are above or below average.
Format only unique or duplicate values
Allows formatting values that are unique or duplicate.
Format only changing values
Allows formatting changing values in real time.
Use a formula to determine which cells to format
Allows specifying a custom condition for the rule.
The Format Cells dialog allows defining the visual appearance of the applied rule. Click the Format button in the New Formatting Rule (or Edit Formatting Rule) dialog to access this window.
Use the Format Cells dialog to specify the following settings:
Call the TableView.ShowConditionalFormattingManager (or TreeListView.ShowConditionalFormattingManager) method to invoke the conditional formatting rules manager in code.
Use the TableView.ConditionalFormattingManagerServiceTemplate (or TreeListView.ConditionalFormattingManagerServiceTemplate) property to define a custom template for the conditional formatting rules manager.