Skip to main content

DataControlBase.SortBy(String) Method

Sorts data by the values of the specified column.

Namespace: DevExpress.UI.Xaml.Grid

Assembly: DevExpress.UI.Xaml.Grid.v21.2.dll

NuGet Package: DevExpress.Uwp.Controls

Declaration

public void SortBy(
    string fieldName
)

Parameters

Name Type Description
fieldName String

A String value that specifies the column’s field name.

Remarks

The Grid Control allows data sorting by multiple columns. Any previous sorting is not cleared when calling the SortBy method.

If the grid’s data isn’t sorted by the specified column, the SortBy method sorts data by its values in ascending order. The new sort order applies an additional sorting condition to the one previously applied.

End-users are allowed to sort data if the grid’s DataControlBase.AllowSorting property is set to true.

See Also