Skip to main content

DevExpress v24.2 Update — Your Feedback Matters

Our What's New in v24.2 webpage includes product-specific surveys. Your response to our survey questions will help us measure product satisfaction for features released in this major update and help us refine our plans for our next major release.

Take the survey Not interested

GridBandCollection.Add() Method

Creates and adds a new band to the end of the collection.

Namespace: DevExpress.XtraGrid.Views.BandedGrid

Assembly: DevExpress.XtraGrid.v24.2.dll

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

#Declaration

public virtual GridBand Add()

#Returns

Type Description
GridBand

A GridBand object representing the band added.

#Remarks

The Add method creates a new band with default settings, adds it to the end of the collection and returns the new band. You can customize the settings of the object returned to provide the band’s desired appearance and functionality. You can also create a band object manually, customize it as needed and then add to the collection using another overload of the Add method.

If you need to add a band to a specific position within the collection, use the GridBandCollection.Insert method. To remove a band from the collection, use the GridBandCollection.Remove method.

See Also