Skip to main content
Tag

PivotGridField.SortOrder Property

Gets or sets the field sort order. This is a dependency property.

Namespace: DevExpress.Xpf.PivotGrid

Assembly: DevExpress.Xpf.PivotGrid.v14.2.dll

#Declaration

[XtraSerializablePropertyId(2)]
[XtraSerializableProperty]
public FieldSortOrder SortOrder { get; set; }

#Property Value

Type Description
FieldSortOrder

A FieldSortOrder enumeration member that specifies the field sort order.

#Remarks

Data within the PivotGridControl is always sorted against fields displayed within Column Header Area and Row Header Area (by default, in ascending order). Use the SortOrder property of these fields to change the current sort order. For other fields, changing the SortOrder property value has no effect on data representation, until these fields are placed within the Column Header Area or Row Header Area.

You can also use the PivotGridField.ChangeSortOrder (synchronous) and PivotGridControl.ChangeFieldSortOrderAsync (asynchronous) methods to toggle a field sort order.

To respond to a field sort order being changed, handle the PivotGridControl.GridLayout event. To implement custom sorting, handle the PivotGridControl.CustomFieldSort event.

See Also