TTMSFNCDataGridConditionalFormatting.AddCellValueRule Method
Adds a
grtCellValuerule that compares a column's value against a reference value.
API unit family: TMSFNCDataGridConditionalFormatting
Declaring type: TTMSFNCDataGridConditionalFormatting
Overloads
Overload 1
Adds a
grtCellValuerule that compares a column's value against a reference value.
function AddCellValueRule(AColumn: Integer; AComparison: TTMSFNCDataGridFormatComparison; const AValue: string): TTMSFNCDataGridFormatRuleItem; overload;
Parameters
| Name | Description |
|---|---|
AColumn |
Zero-based column index the rule applies to. |
AComparison |
The comparison operator to use. |
AValue |
The reference value compared against the cell value. |
Returns
The newly added rule.
Overload 2
Adds a
grtCellValuerule that compares a column's value against a typed reference value.
function AddCellValueRule(AColumn: Integer; AComparison: TTMSFNCDataGridFormatComparison; const AValue: TTMSFNCValue): TTMSFNCDataGridFormatRuleItem; overload;
Parameters
| Name | Description |
|---|---|
AColumn |
Zero-based column index the rule applies to. |
AComparison |
The comparison operator to use. |
AValue |
The reference value compared against the cell value. |
Returns
The newly added rule.
Overload 3
Adds a
grtCellValuerule that compares a column's value against two typed bounds, for agfcBetweenorgfcNotBetweencomparison. Both bounds are inclusive and their order does not matter.
function AddCellValueRule(AColumn: Integer; AComparison: TTMSFNCDataGridFormatComparison; const AFrom, ATo: TTMSFNCValue): TTMSFNCDataGridFormatRuleItem; overload;
Parameters
| Name | Description |
|---|---|
AColumn |
Zero-based column index the rule applies to. |
AComparison |
The comparison operator to use, normally gfcBetween or gfcNotBetween. |
AFrom |
The first bound, inclusive. |
ATo |
The second bound, inclusive. |
Returns
The newly added rule.