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

DataGridView.SortMode Property

Gets or sets whether the grid allows data sorting by multiple columns or by a single column only. This is a bindable property.

Namespace: DevExpress.Maui.DataGrid

Assembly: DevExpress.Maui.DataGrid.dll

NuGet Package: DevExpress.Maui.DataGrid

#Declaration

C#
public GridSortMode SortMode { get; set; }

#Property Value

Type Default Description
GridSortMode Single

A GridSortMode enumeration value.

Available values:

Name Description
Single

Grid data can be sorted only by a single column at a time.

Multiple

Grid data can be sorted by multiple columns.

#Remarks

To control whether sorting is available for users, use the DataGridView.AllowSort or GridColumn.AllowSort property.

Refer to the following topic for more information about the sorting functionality in the Data Grid View: How to Sort Rows in DevExpress Data Grid for .NET MAUI.

#Example

The following example enables multi-column sorting in a grid:

<dxg:DataGridView SortMode="Multiple">
    <!--...-->
</dxg:DataGridView>
See Also