FieldFilterValues.FilterType Property

Gets or sets the field's filter type.

Namespace: DevExpress.Xpf.PivotGrid

Assembly: DevExpress.Xpf.PivotGrid.v20.1.dll

Declaration

[DefaultValue(FieldFilterType.Excluded)]
public FieldFilterType FilterType { get; set; }
<DefaultValue(FieldFilterType.Excluded)>
Public Property FilterType As FieldFilterType

Property Value

Type Default Description
FieldFilterType

Excluded

A FieldFilterType enumeration value which specifies the field's filter type.

Remarks

The FilterType property specifies whether only the records that contain values from the PivotGridFieldFilterValues.Values array of a specific field are displayed in a pivot grid.

If the FilterType property is set to the FieldFilterType.Included value, only the records which contain values from the PivotGridFieldFilterValues.Values array of a specific field are displayed by a pivot grid. Otherwise, if the FilterType property is set to the FieldFilterType.Excluded value, only records that don't contain values from the PivotGridFieldFilterValues.Values array of a specific field are displayed.

NOTE

The FilterType property is not in effect when you set filter values in the Excel-style pop-up filter.

Examples

This example shows how to apply a filter to a field.

The first filter selects records which contain UK in the fieldCountry field, the second filter selects four categories in the fieldCategoryName field: Beverages, Condiments, Seafood, and Produce.

NOTE

A complete sample project is available at How to Apply a Filter to a Field.

    fieldCountry.SetFilterValues(new string[] { "UK" }, FieldFilterType.Included, true);
    fieldCategoryName.SetFilterValues(new string[] { "Beverages", "Condiments", "Seafood", "Produce" }, FieldFilterType.Included, true);
See Also