The requested page is not available for the requested platform. You are viewing the content for .NET Framework 4.5.2+ platform.
.NET Framework 4.5.2+
.NET Framework 4.5.2+
.NET Standard 2.0+

XPServerCollectionSource.DefaultSorting Property

Specifies how data source contents are sorted by default, when sort order is not specified by the bound control.

Namespace: DevExpress.Xpo

Assembly: DevExpress.Xpo.v19.1.dll

Declaration

public string DefaultSorting { get; set; }
Public Property DefaultSorting As String
public string DefaultSorting { get; set; }
Public Property DefaultSorting As String

Property Value

Type Description
String

A String object which contains the names of the columns against which data source contents are sorted.

Property Value

Type Description
String

A String object which contains the names of the columns against which data source contents are sorted.

Remarks

This property accepts a string containing a column name followed by the sort order - "ASC" (ascending) or "DESC" (descending).


dataSource.DefaultSorting = "UnitPrice DESC";

Columns are sorted ascending by default - "ASC" can be omitted.


dataSource.DefaultSorting = "Name";

Multiple columns can be separated by semicolons.


dataSource.DefaultSorting = "UnitPrice DESC; Name";
See Also