Skip to main content

DevExpress v24.2 Update — Your Feedback Matters

Our What's New in v24.2 webpage includes product-specific surveys. Your response to our survey questions will help us measure product satisfaction for features released in this major update and help us refine our plans for our next major release.

Take the survey Not interested

FilterField Class

A filter field that specifies edit settings and predefined filters.

Namespace: DevExpress.Xpf.Core.FilteringUI

Assembly: DevExpress.Xpf.Grid.v24.2.dll

NuGet Package: DevExpress.Wpf.Grid.Core

#Declaration

public class FilterField :
    Freezable

The following members return FilterField objects:

#Remarks

Specify the FilterBehavior.Fields property to configure display fields, edit settings, and predefined filters.

The following code sample shows how to use the FilterBehavior to allow the Filter Elements to work with the ListBoxEdit.

<dxe:ListBoxEdit Name="listBoxEdit" ItemsSource="{Binding Products}"
                 FilterCriteria="{Binding ElementName=filterBehavior, Path=ActualFilterCriteria}"/>

<!-- -->    

<dxfui:CheckedListFilterElement FieldName="CategoryName">
    <dxmvvm:Interaction.Behaviors>
        <dxfui:FilterBehavior x:Name="filterBehavior" ItemsSource="{Binding ElementName=listBoxEdit, Path=ItemsSource}">
            <dxfui:FilterField FieldName="CategoryName">
                <dxe:ComboBoxEditSettings ItemsSource="{Binding Categories}"/>
            </dxfui:FilterField>
        </dxfui:FilterBehavior>
    </dxmvvm:Interaction.Behaviors>
</dxfui:CheckedListFilterElement>

Run Demo: FilterBehavior

See Also