wpf-devexpress-dot-xpf-dot-grid-dot-formatconditioncollection-dot-addrange-x28-system-dot-collections-dot-generic-dot-ienumerable-devexpress-dot-xpf-dot-grid-dot-formatconditionbase-x29.md
Adds a range of conditional formats to the collection.
Namespace : DevExpress.Xpf.Grid
Assembly : DevExpress.Xpf.Grid.v25.2.Core.dll
NuGet Package : DevExpress.Wpf.Grid.Core
public void AddRange(
IEnumerable<FormatConditionBase> conditionals
)
Public Sub AddRange(
conditionals As IEnumerable(Of FormatConditionBase)
)
| Name | Type | Description |
|---|---|---|
| conditionals | IEnumerable<FormatConditionBase> |
A range of conditional formats.
|
The following code sample adds conditional formats to the TableView.FormatConditions collection:
view.FormatConditions.AddRange(new List<FormatConditionBase> {
new FormatCondition() {
FieldName = "ModelPrice",
ValueRule=ConditionRule.Greater,
Value1="50000",
PredefinedFormatName="LightRedFillWithDarkRedText"
},
new IconSetFormatCondition () {
FieldName = "Discount",
PredefinedFormatName = "Stars3IconSet"
}
});
The collection contains the Add and AddRange methods to add conditional formats:
The following code snippet (auto-collected from DevExpress Examples) contains a reference to the AddRange(IEnumerable<FormatConditionBase>) method.
Note
The algorithm used to collect these code examples remains a work in progress. Accordingly, the links and snippets below may produce inaccurate results. If you encounter an issue with code examples below, please use the feedback form on this page to report the issue.
InitializeComponent();
view.FormatConditions.AddRange(new List<FormatConditionBase> {
new DataBarFormatCondition() {
See Also
FormatConditionCollection Class