PivotGridControl.ActiveFilter Property

Provides access to settings of the filter applied to the PivotGridControl's data.

Namespace: DevExpress.XtraPivotGrid

Assembly: DevExpress.XtraPivotGrid.v20.1.dll

Declaration

[DXCategory("Data")]
[PivotAPIMemberCategory(APICategory.RelationalSource)]
[XtraSerializableProperty(XtraSerializationVisibility.Hidden)]
public PivotFilter ActiveFilter { get; }
<PivotAPIMemberCategory(APICategory.RelationalSource)>
<XtraSerializableProperty(XtraSerializationVisibility.Hidden)>
<DXCategory("Data")>
Public ReadOnly Property ActiveFilter As PivotFilter

Property Value

Type Description
PivotFilter

A PivotFilter object that is a filter applied to data displayed in the PivotGridControl.

Remarks

To learn more about filtering, see Filtering Overview.

NOTE

Filter Panel and Filter Editor display ActiveFilter instead of PivotGridControl.Prefilter if the following conditions are met:

Examples

The example below shows how to apply complex filter criteria in code using the PivotFilter.Criteria property. This property is exposed by the PivotFilter object that can be accessed using PivotGridControl.ActiveFilter.

using DevExpress.Data.Filtering;
// ...
            pivotGridControl.ActiveFilter.Criteria = new GroupOperator(GroupOperatorType.And,
                new InOperator(fieldTrademark.PrefilterColumnName, new string[] { "Chevrolet", "Chrysler", "Dodge", "Ford" }),
                new InOperator(fieldBodyStyle.PrefilterColumnName, new string[] { "Coupe" }));
See Also