Skip to main content
Table of Contents

TTMSFNCCustomDataGrid.GroupSort Method

Sorts the rows inside every group on a column, keeping the groups themselves in place.

API unit family: TMSFNCDataGrid Declaring type: TTMSFNCCustomDataGrid

Overloads

Overload 1

Sorts the rows inside every group on a column, keeping the groups themselves in place.

FMX.TMSFNCDataGrid.hppPascalC++
procedure GroupSort(AColumn: Integer; ADirection: TTMSFNCDataGridSortDirection); overload;
void __fastcall GroupSort(int AColumn, TTMSFNCDataGridSortDirection ADirection)/* overload */;

Remarks

Only the child rows of the innermost groups are sorted; the order of the group node rows is not changed.

Parameters

Name Description
AColumn Zero-based column index to sort on.
ADirection Sort direction.

Overload 2

Sorts the rows inside every group on several columns, keeping the groups themselves in place.

FMX.TMSFNCDataGrid.hppPascalC++
procedure GroupSort(AColumns: TArray<Integer>; ADirections: TArray<TTMSFNCDataGridSortDirection>; ACustomCompareCallback: TTMSFNCDataGridDataCustomCompareCallback = nil; ASortOptionsCallback: TTMSFNCDataGridDataGetSortOptionsCallback = nil); reintroduce; overload;
void __fastcall GroupSort(System::DynamicArray<int> AColumns, System::DynamicArray<TTMSFNCDataGridSortDirection> ADirections, Fmx::Tmsfncdatagriddata::_di_TTMSFNCDataGridDataCustomCompareCallback ACustomCompareCallback = Fmx::Tmsfncdatagriddata::_di_TTMSFNCDataGridDataCustomCompareCallback(), Fmx::Tmsfncdatagriddata::_di_TTMSFNCDataGridDataGetSortOptionsCallback ASortOptionsCallback = Fmx::Tmsfncdatagriddata::_di_TTMSFNCDataGridDataGetSortOptionsCallback())/* overload */;

Parameters

Name Description
AColumns Zero-based column indexes, primary sort column first.
ADirections Sort direction per entry of AColumns.
ACustomCompareCallback Optional callback for custom value comparison.
ASortOptionsCallback Optional callback that adjusts the sort options.