Back to Devexpress

GridControl.GroupBy(GridColumn, Boolean) Method

wpf-devexpress-dot-xpf-dot-grid-dot-gridcontrol-dot-groupby-x28-devexpress-dot-xpf-dot-grid-dot-gridcolumn-system-dot-boolean-x29.md

latest2.0 KB
Original Source

GridControl.GroupBy(GridColumn, Boolean) Method

Groups data by the values of the specified column.

Namespace : DevExpress.Xpf.Grid

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

NuGet Package : DevExpress.Wpf.Grid.Core

Declaration

csharp
public void GroupBy(
    GridColumn column,
    bool mergeWithPreviousGroup = false
)
vb
Public Sub GroupBy(
    column As GridColumn,
    mergeWithPreviousGroup As Boolean = False
)

Parameters

NameTypeDescription
columnGridColumn

A GridColumn object that represents the column by whose values data is grouped.

|

Optional Parameters

NameTypeDefaultDescription
mergeWithPreviousGroupBooleanFalse

A boolean value that specifies whether the current grouping should be merged with a previous grouping (according to group index).

|

Remarks

The GridControl supports data grouping by an unlimited number of columns. The GroupBy method groups data by the values of the specified column.

Data rows are always sorted against the grouping columns. If data is grouped against a column which isn’t sorted, the grid automatically applies sorting in ascending order to this column.

To learn more, see Grouping.

See Also

GridControl Class

GridControl Members

DevExpress.Xpf.Grid Namespace