Prefilter.Criteria Property
Gets or sets the Prefilter‘s expression.
Namespace: DevExpress.XtraPivotGrid
Assembly: DevExpress.XtraPivotGrid.v19.2.dll
Declaration
Property Value
Type | Description |
---|---|
CriteriaOperator | A CriteriaOperator object that represents the Prefilter‘s expression. |
Remarks
Use the Criteria property to obtain the filter expression, which is specified by an end-user in the Prefilter editor. For more information, see the PivotGridControl.Prefilter property description.
Note
The Prefilter is not supported in OLAP mode.
Example
The following code shows how to filter a Pivot Grid Control’s underlying data source using the Prefilter. The filter selects records that contain ‘USA’ or ‘UK’ strings in the Country field.
using DevExpress.Data.Filtering;
//...
pivotgridControl1.Prefilter.CriteriaString = "[" + fieldCountry.PrefilterColumnName +
"] = 'UK' OR [" + fieldCountry.PrefilterColumnName + "] = 'USA'";
Related GitHub Examples
The following code snippet (auto-collected from DevExpress Examples) contains a reference to the Criteria 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.