Skip to main content

GridGroupSummaryItemCollection.Add() Method

Creates a new group summary item with default settings and adds it to the end of the collection.

Namespace: DevExpress.XtraGrid

Assembly: DevExpress.XtraGrid.v23.2.dll

NuGet Packages: DevExpress.Win.Grid, DevExpress.Win.Navigation

Declaration

public GridGroupSummaryItem Add()

Returns

Type Description
GridGroupSummaryItem

A GridGroupSummaryItem object representing the new summary item.

Remarks

You should modify property values of the object obtained to customize the summary item as needed. Alternatively, you can use another Add method’s overload that specifies the new summary item’s settings as parameters.

If you need to add several group summary items to the collection, consider using the GridSummaryItemCollection.BeginUpdate and GridSummaryItemCollection.EndUpdate methods to prevent the collection from being updated until all required items are added. Alternatively, you can use the GridSummaryItemCollection.AddRange method, which adds a predefined array of summary items.

To remove a group summary item from the collection, use the GridSummaryItemCollection.Remove method.

See Also