Back to Devexpress

DataControlBase.FilterGroupSortChanging Event

wpf-devexpress-dot-xpf-dot-grid-dot-datacontrolbase-fe76f032.md

latest7.1 KB
Original Source

DataControlBase.FilterGroupSortChanging Event

Occurs when group, sort, or filter options are changed.

Namespace : DevExpress.Xpf.Grid

Assembly : DevExpress.Xpf.Grid.v25.2.Core.dll

NuGet Package : DevExpress.Wpf.Grid.Core

Declaration

csharp
public event FilterGroupSortChangingEventHandler FilterGroupSortChanging
vb
Public Event FilterGroupSortChanging As FilterGroupSortChangingEventHandler

Event Data

The FilterGroupSortChanging event's data class is FilterGroupSortChangingEventArgs. The following properties provide information specific to this event:

PropertyDescription
ComplexFilterCriteriaGets the complex filter that is applied to several columns.
GroupCountGets or sets the number of group sortings.
HandledGets or sets a value that indicates the present state of the event handling for a routed event as it travels the route. Inherited from RoutedEventArgs.
OriginalSourceGets the original reporting source as determined by pure hit testing, before any possible Source adjustment by a parent class. Inherited from RoutedEventArgs.
RoutedEventGets or sets the RoutedEvent associated with this RoutedEventArgs instance. Inherited from RoutedEventArgs.
SearchStringGets or sets the search panel’s string.
SortInfoGets information about the GridControl’s sorting.
SourceGets the GridControl.
SplitColumnFiltersGets filters applied to columns.

The event data class exposes the following methods:

MethodDescription
InvokeEventHandler(Delegate, Object)When overridden in a derived class, provides a way to invoke event handlers in a type-specific way, which can increase efficiency over the base implementation. Inherited from RoutedEventArgs.
IsFilteredBy(String)Gets whether the GridControl is filtered by the field name.
IsGroupedBy(String)Gets whether the GridControl is grouped by the field name.
IsSortedBy(String)Gets whether the GridControl is sorted by the field name.
OnSetSource(Object)When overridden in a derived class, provides a notification callback entry point whenever the value of the Source property of an instance changes. Inherited from RoutedEventArgs.

Remarks

The FilterGroupSortChanging event allows you to modify applied sort, group, filter, and search options. To do this, use event arguments only (do not modify GridControl properties).

The following code snippet (auto-collected from DevExpress Examples) contains a reference to the FilterGroupSortChanging event.

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.

wpf-data-grid-bind-to-custom-service-with-restrictions/CS/MainWindow.xaml#L14

xml
<Grid>
    <dxg:GridControl x:Name="grid" FilterGroupSortChanging="OnFilterGroupSortChanging">
        <dxg:GridControl.Columns>

wpf-data-grid-bind-to-custom-service-with-restrictions/CS/obj/Debug/net8.0-windows/MainWindow.g.cs#L124

csharp
#line 14 "..\..\..\MainWindow.xaml"
this.grid.FilterGroupSortChanging += new DevExpress.Xpf.Grid.FilterGroupSortChangingEventHandler(this.OnFilterGroupSortChanging);

wpf-data-grid-bind-to-custom-service-with-restrictions/VB/obj.NetFX/Debug/MainWindow.g.vb#L121

vb
#ExternalSource("..\..\MainWindow.xaml",14)
AddHandler Me.grid.FilterGroupSortChanging, New DevExpress.Xpf.Grid.FilterGroupSortChangingEventHandler(AddressOf Me.OnFilterGroupSortChanging)

See Also

DataControlBase Class

DataControlBase Members

DevExpress.Xpf.Grid Namespace