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

PropertyGridControl.Sort Event

Enables you to sort data using custom rules.

Namespace: DevExpress.Xpf.PropertyGrid

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

NuGet Package: DevExpress.Wpf.PropertyGrid

#Declaration

public event PropertyGridSortingEventHandler Sort

#Event Data

The Sort event's data class is DevExpress.Xpf.PropertyGrid.PropertyGridSortingEventArgs.

#Remarks

To sort property grid data using custom logic, set its PropertyGridControl.SortMode property to PropertyGridSortMode.Custom, and handle the Sort event.

The event parameter’s Handled property should be set to true if the comparison operation was handled. You can leave this parameter set to false to invoke the default comparison mechanism after your event handler has finished. In this instance, the custom comparison operation’s result is ignored.

See Also