Skip to main content
All docs
V24.1

FilterPopupExcelEventArgs.HideFilter(CustomUIFilterType) Method

Hides an operator from the Filters tab.

Namespace: DevExpress.XtraPivotGrid

Assembly: DevExpress.XtraPivotGrid.v24.1.dll

NuGet Package: DevExpress.Win.PivotGrid

Declaration

public bool HideFilter(
    CustomUIFilterType filterType
)

Parameters

Name Type Description
filterType DevExpress.Utils.Filtering.Internal.CustomUIFilterType

An operator that should be hidden.

Returns

Type Description
Boolean

true if the operator is added to a list of hidden operators; false if the operator is already in the list.

Remarks

The following code sample hides operators from the Filters tab:

WinForms PivotGrid - Hide Operators from the Excel Filter

void PivotGridControl_ShowFilterPopupExcel(object sender, FilterPopupExcelEventArgs e) {
    if (e.Field == fieldModelPrice) {
        e.HideFilter(DevExpress.Utils.Filtering.Internal.CustomUIFilterType.BelowAverage);
        e.HideFilter(DevExpress.Utils.Filtering.Internal.CustomUIFilterType.Between);
        e.HideFilter(DevExpress.Utils.Filtering.Internal.CustomUIFilterType.BottomN);
        e.HideFilter(DevExpress.Utils.Filtering.Internal.CustomUIFilterType.Custom);
        e.HideFilter(DevExpress.Utils.Filtering.Internal.CustomUIFilterType.DoesNotEqual);
        e.HideFilter(DevExpress.Utils.Filtering.Internal.CustomUIFilterType.InRange);
        e.HideFilter(DevExpress.Utils.Filtering.Internal.CustomUIFilterType.LessThan);
        e.HideFilter(DevExpress.Utils.Filtering.Internal.CustomUIFilterType.LessThanOrEqualTo);
    }
}

When you hide filters displayed in Specific Date Periods, the remaining filters are displayed as a checked list.

See Also