Skip to main content

DataControlBase.AllowSorting Property

Gets or sets whether an end-user can sort data. This is a dependency property.

Namespace: DevExpress.UI.Xaml.Grid

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

NuGet Package: DevExpress.Uwp.Controls

Declaration

[XtraSerializableProperty]
public bool AllowSorting { get; set; }

Property Value

Type Description
Boolean

true to allow an end-user to sort data; otherwise, false.

Remarks

End-users are allowed to sort data if the grid’s AllowSorting property is set to true. Individual columns provide the ColumnBase.AllowSorting property, allowing the default behavior specified by the grid to be overridden. Setting this property to ‘True’ or ‘False’ overrides the default behavior. This can be useful when it is required to prevent an end-user from sorting data by the values of specific columns.

If the AllowSorting property is set to true, end-users can sort data by the desired column by clicking its header.

If a column’s ColumnBase.AllowSorting property is set to ‘Default’, the ability to sort data by its values is controlled by the grid’s AllowSorting property. In this instance, to obtain whether an end-user can sort data by the current column, use the ColumnBase.ActualAllowSorting property.

See Also