Back to Devexpress

ColumnBase.AllowedSortOrders Property

wpf-devexpress-dot-xpf-dot-grid-dot-columnbase-fcc3c8b9.md

latest4.3 KB
Original Source

ColumnBase.AllowedSortOrders Property

Gets or sets allowed sorting orders that the GridControl‘s column supports.

Namespace : DevExpress.Xpf.Grid

Assembly : DevExpress.Xpf.Grid.v25.2.Core.dll

NuGet Package : DevExpress.Wpf.Grid.Core

Declaration

csharp
public AllowedSortOrders AllowedSortOrders { get; set; }
vb
Public Property AllowedSortOrders As AllowedSortOrders

Property Value

TypeDescription
AllowedSortOrders

Allowed sorting orders that the GridControl ‘s column supports.

|

Available values:

NameDescription
Ascending

Values can be sorted in ascending order.

| | Descending |

Values can be sorted in descending order.

| | All |

Values can be sorted in any order.

|

The following code snippets (auto-collected from DevExpress Examples) contain references to the AllowedSortOrders property.

Note

The algorithm used to collect these code examples remains a work in progress. Accordingly, the links and snippets below may produce inaccurate results. If you encounter an issue with code examples below, please use the feedback form on this page to report the issue.

wpf-data-grid-bind-to-custom-service-with-restrictions/CS/MainWindow.xaml#L16

xml
<dxg:GridControl.Columns>
    <dxg:GridColumn x:Name="hotColumn" FieldName="Hot" Visible="False" ShowInColumnChooser="False" AllowSorting="True" AllowedSortOrders="Descending" SortOrder="Descending" />
    <dxg:GridColumn x:Name="weekColumn" FieldName="Week" Visible="False" ShowInColumnChooser="False" AllowSorting="True" AllowedSortOrders="Descending" />

wpf-data-grid-bind-to-pagedasyncsource/CS/PagedAsyncSourceSample/MainWindow.xaml#L17

xml
<dxg:GridColumn FieldName="Created" IsSmart="True" Width="*"
                AllowSorting="True" AllowedSortOrders="Descending"
                AllowedDateTimeFilters="SingleDateRange" FilterPopupMode="DateSmart">

wpf-data-grid-bind-to-infiniteasyncsource/CS/InfiniteAsyncSourceSample/MainWindow.xaml#L21

xml
<dxg:GridColumn FieldName="Created" IsSmart="True" AllowEditing="True" Width="*"
                AllowSorting="True" AllowedSortOrders="Descending"
                AllowedDateTimeFilters="SingleDateRange" FilterPopupMode="DateSmart">

how-to-bind-to-grpc/CS/InfiniteAsyncSource.GRPC/MainWindow.xaml#L37

xml
<dxg:GridColumn FieldName="Created" IsSmart="True" Width="*"
                        AllowSorting="True" AllowedSortOrders="Descending"
                        AllowedDateTimeFilters="SingleDateRange" FilterPopupMode="DateSmart" AllowEditing="true">

wpf-data-grid-use-virtual-sources-to-bind-to-in-memory-data/CS/MainWindow.xaml#L17

xml
<dxg:GridColumn FieldName="Created" IsSmart="True" Width="*"
                AllowSorting="True" AllowedSortOrders="Descending"
                AllowedDateTimeFilters="SingleDateRange" FilterPopupMode="DateSmart">

See Also

ColumnBase Class

ColumnBase Members

DevExpress.Xpf.Grid Namespace