Back to Devexpress

TopBottomRuleFormatCondition.Threshold Property

wpf-devexpress-dot-xpf-dot-grid-dot-topbottomruleformatcondition-da03198c.md

latest2.8 KB
Original Source

TopBottomRuleFormatCondition.Threshold Property

Specifies the number or percentage of cells (or corresponding rows) to format. This is a dependency property.

Namespace : DevExpress.Xpf.Grid

Assembly : DevExpress.Xpf.Grid.v25.2.Core.dll

NuGet Package : DevExpress.Wpf.Grid.Core

Declaration

csharp
public double Threshold { get; set; }
vb
Public Property Threshold As Double

Property Value

TypeDescription
Double

A number of cells to format.

|

Remarks

The Threshold property is in effect for the following rules:

Depending on the rule, the Threshold property is used to specify either the number or percentage of cells (or corresponding rows) to format.

The following code snippet (auto-collected from DevExpress Examples) contains a reference to the Threshold property.

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.

wpf-data-grid-apply-conditional-formatting/CS/ConditionalFormatting/MainWindow.xaml#L23

xml
<dxg:DataBarFormatCondition FieldName="Sales" PredefinedFormatName="RedGradientDataBar"/>
<dxg:TopBottomRuleFormatCondition Expression="[Sales]" Rule="TopPercent" Threshold="10" PredefinedFormatName="BoldText"/>
<dxg:FormatCondition Expression="[SalesVsTarget] &lt; 0.0m" FieldName="SalesVsTarget" PredefinedFormatName="RedText"/>

See Also

Rule

TopBottomRuleFormatCondition Class

TopBottomRuleFormatCondition Members

DevExpress.Xpf.Grid Namespace