Log In
Home
Support
Demos
Documentation
Blogs
Training
Webinars
[Expand]Welcome to DevExpress .NET Documentation
[Expand]WinForms Controls
[Expand]ASP.NET Controls and MVC Extensions
[Expand]ASP.NET Bootstrap Controls
[Expand]ASP.NET Core Bootstrap Controls
[Expand]WPF Controls
[Expand]Xamarin Controls
[Expand]Windows 10 App Controls
[Expand]Document Server
[Collapse]Reporting
 [Expand]Product Information
 [Expand]Creating Reports in Visual Studio
 [Expand]Creating End-User Reporting Applications
 [Collapse]API Reference
  [Expand]DevExpress.XtraCharts
  [Expand]DevExpress.XtraReports
  [Expand]DevExpress.XtraReports.Configuration
  [Expand]DevExpress.XtraReports.Data
  [Expand]DevExpress.XtraReports.Design
  [Expand]DevExpress.XtraReports.Expressions
  [Expand]DevExpress.XtraReports.Extensions
  [Expand]DevExpress.XtraReports.Localization
  [Expand]DevExpress.XtraReports.Native
  [Expand]DevExpress.XtraReports.ReportGallery
  [Expand]DevExpress.XtraReports.ReportGeneration
  [Expand]DevExpress.XtraReports.Security
  [Expand]DevExpress.XtraReports.Serialization
  [Expand]DevExpress.XtraReports.Service
  [Expand]DevExpress.XtraReports.Service.Extensions
  [Expand]DevExpress.XtraReports.Templates
  [Collapse]DevExpress.XtraReports.UI
   [Expand]Band Class
   [Collapse]BandCollection Class
     BandCollection Members
     BandCollection Constructor
    [Expand]BandCollection Properties
    [Expand]BandCollection Methods
   [Expand]BandEventArgs Class
    BandEventHandler Delegate
   [Expand]BandFactory Class
    BandKind Enumeration
   [Expand]BandScripts Class
   [Expand]BindingEventArgs Class
    BindingEventHandler Delegate
   [Expand]BottomMarginBand Class
   [Expand]CalculatedField Class
   [Expand]CalculatedFieldCollection Class
   [Expand]CalculatedFieldScripts Class
   [Expand]ChangeEventArgs Class
    ChangeEventHandler Delegate
    ChartImageType Enumeration
   [Expand]CheckEditOptions Class
    ColumnDirection Enumeration
    DataBindingMode Enumeration
   [Expand]DataSourceRowEventArgs Class
    DataSourceRowEventHandler Delegate
   [Expand]DesignerOptions Class
    DesignWindowType Enumeration
   [Expand]DetailBand Class
   [Expand]DetailReportBand Class
   [Expand]DetailReportBandCollection Class
    DocumentExportMode Enumeration
   [Expand]DrawEventArgs Class
    DrawEventHandler Delegate
   [Expand]EditOptions Class
   [Expand]ExpressionBinding Class
   [Expand]ExpressionBindingCollection Class
   [Expand]Formatting Class
   [Expand]FormattingRule Class
   [Expand]FormattingRuleCollection Class
   [Expand]FormattingRuleSheet Class
    GaugeImageType Enumeration
   [Expand]GetValueEventArgs Class
    GetValueEventHandler Delegate
   [Expand]GroupBand Class
   [Expand]GroupBandScripts Class
   [Expand]GroupField Class
   [Expand]GroupFieldCollection Class
   [Expand]GroupFooterBand Class
    GroupFooterUnion Enumeration
   [Expand]GroupHeaderBand Class
   [Expand]GroupHeaderBandScripts Class
   [Expand]GroupSortingSummaryGetResultEventArgs Class
    GroupSortingSummaryGetResultEventHandler Delegate
   [Expand]GroupSortingSummaryRowChangedEventArgs Class
    GroupSortingSummaryRowChangedEventHandler Delegate
    GroupUnion Enumeration
   [Expand]HtmlEventArgs Class
    HtmlEventHandler Delegate
   [Expand]IReportDesignTool Interface
   [Expand]MarginBand Class
   [Expand]MultiColumn Class
    MultiColumnMode Enumeration
   [Expand]PageBand Class
    PageBreak Enumeration
   [Expand]PageFooterBand Class
   [Expand]PageHeaderBand Class
   [Expand]ParameterBinding Class
   [Expand]ParameterBindingCollection Class
   [Expand]PdfStreamingExporter Class
   [Expand]PreviewMouseEventArgs Class
    PreviewMouseEventHandler Delegate
   [Expand]PrintableComponentContainer Class
   [Expand]PrintOnPageEventArgs Class
    PrintOnPageEventHandler Delegate
    ProcessDuplicatesMode Enumeration
    ProcessDuplicatesTarget Enumeration
    PromptBoolean Enumeration
   [Expand]ReportDesignTool Class
   [Expand]ReportFooterBand Class
   [Expand]ReportHeaderBand Class
   [Expand]ReportPrintOptions Class
    ReportUnit Enumeration
   [Expand]ReportUnitExtensions Class
    RestrictionLevel Enumeration
    RightToLeft Enumeration
    RightToLeftLayout Enumeration
   [Expand]SaveComponentsEventArgs Class
   [Expand]SerializableString Class
    SerializationFormat Enumeration
    SnappingMode Enumeration
   [Expand]SortingOptions Class
    SortingSummaryFunction Enumeration
    SparklineImageType Enumeration
   [Expand]StyleFlagsBase Class
   [Expand]StylePriority Class
   [Expand]StyleUsing Class
   [Expand]SubBand Class
   [Expand]SubBandCollection Class
   [Expand]SubreportBase Class
   [Expand]SubreportBaseScripts Class
    SummaryFunc Enumeration
   [Expand]SummaryGetResultEventArgs Class
    SummaryGetResultHandler Delegate
    SummaryRunning Enumeration
   [Expand]TextEditOptions Class
   [Expand]TextFormatEventArgs Class
    TextFormatEventHandler Delegate
   [Expand]TopMarginBand Class
   [Expand]TruncatedControlScripts Class
   [Expand]ValueBinding Class
    ValueSuppressType Enumeration
   [Expand]WinControlContainer Class
    WinControlDrawMethod Enumeration
    WinControlImageType Enumeration
    WinControlPrintMode Enumeration
   [Expand]WindowControlOptions Class
   [Expand]XRAppearanceObject Class
   [Expand]XRBarCode Class
    XRBarCodeOrientation Enumeration
   [Expand]XRBinding Class
   [Expand]XRBindingCollection Class
   [Expand]XRCharacterComb Class
   [Expand]XRCharacterCombScripts Class
   [Expand]XRChart Class
   [Expand]XRChartScripts Class
   [Expand]XRCheckBox Class
    XRColumnSortOrder Enumeration
   [Expand]XRControl Class
   [Expand]XRControlCollection Class
   [Expand]XRControlCollectionBase Class
   [Expand]XRControlEvents Class
   [Expand]XRControlScripts Class
   [Expand]XRControlStyle Class
   [Expand]XRControlStyleSheet Class
   [Expand]XRCrossBandBox Class
   [Expand]XRCrossBandControl Class
   [Expand]XRCrossBandControlCollection Class
   [Expand]XRCrossBandLine Class
    XRDockStyle Enumeration
   [Expand]XRFieldEmbeddableControl Class
   [Expand]XRGauge Class
   [Expand]XRGaugeScripts Class
   [Expand]XRGroupSortingSummary Class
   [Expand]XRLabel Class
   [Expand]XRLabelScripts Class
   [Expand]XRLine Class
   [Expand]XRLineScripts Class
   [Expand]XRPageBreak Class
   [Expand]XRPageBreakScripts Class
   [Expand]XRPageInfo Class
   [Expand]XRPanel Class
   [Expand]XRPanelScripts Class
   [Expand]XRPictureBox Class
   [Expand]XRPictureboxScripts Class
   [Expand]XRPivotGrid Class
   [Expand]XRPivotGridScripts Class
   [Expand]XRRichText Class
   [Expand]XRRichTextBase Class
   [Expand]XRRichTextBox Class
   [Expand]XRRichTextBoxBase Class
    XRRichTextStreamType Enumeration
   [Expand]XRScriptsBase Class
   [Expand]XRShape Class
   [Expand]XRShapeScripts Class
   [Expand]XRSparkline Class
   [Expand]XRSparklineScripts Class
   [Expand]XRSubreport Class
   [Expand]XRSummary Class
   [Expand]XRSummaryEvents Class
   [Expand]XRSummaryScripts Class
   [Expand]XRTable Class
   [Expand]XRTableCell Class
   [Expand]XRTableCellCollection Class
   [Expand]XRTableOfContents Class
   [Expand]XRTableOfContentsLevel Class
   [Expand]XRTableOfContentsLevelBase Class
   [Expand]XRTableOfContentsLevelCollection Class
   [Expand]XRTableOfContentsTitle Class
   [Expand]XRTableRow Class
   [Expand]XRTableRowCollection Class
   [Expand]XRTableScripts Class
   [Expand]XRWatermark Class
   [Expand]XRZipCode Class
   [Expand]XtraReport Class
   [Expand]XtraReportBase Class
   [Expand]XtraReportBaseScripts Class
   [Expand]XtraReportExtensions Class
   [Expand]XtraReportScripts Class
  [Expand]DevExpress.XtraReports.UI.BarCode
  [Expand]DevExpress.XtraReports.UI.PivotGrid
  [Expand]DevExpress.XtraReports.UserDesigner
  [Expand]DevExpress.XtraReports.Web
  [Expand]DevExpress.XtraReports.Web.Azure.ReportDesigner
  [Expand]DevExpress.XtraReports.Web.Azure.WebDocumentViewer
  [Expand]DevExpress.XtraReports.Web.ClientControls
  [Expand]DevExpress.XtraReports.Web.ClientControls.DataContracts
  [Expand]DevExpress.XtraReports.Web.DocumentViewer
  [Expand]DevExpress.XtraReports.Web.DocumentViewer.Ribbon
  [Expand]DevExpress.XtraReports.Web.Extensions
  [Expand]DevExpress.XtraReports.Web.Localization
  [Expand]DevExpress.XtraReports.Web.QueryBuilder
  [Expand]DevExpress.XtraReports.Web.QueryBuilder.Native
  [Expand]DevExpress.XtraReports.Web.ReportDesigner
  [Expand]DevExpress.XtraReports.Web.ReportDesigner.DataContracts
  [Expand]DevExpress.XtraReports.Web.ReportDesigner.Native
  [Expand]DevExpress.XtraReports.Web.Scripts
  [Expand]DevExpress.XtraReports.Web.WebDocumentViewer
  [Expand]DevExpress.XtraReports.Web.WebDocumentViewer.DataContracts
  [Expand]DevExpress.XtraReports.Web.WebDocumentViewer.Native
  [Expand]DevExpress.XtraReports.Wizards
  [Expand]DevExpress.XtraReports.Wizards.Builder
  [Expand]DevExpress.XtraReports.Wizards.Labels
  [Expand]DevExpress.XtraReports.Wizards.Presenters
  [Expand]DevExpress.XtraReports.Wizards.Templates
  [Expand]DevExpress.XtraReports.Wizards.Views
  [Expand]DevExpress.XtraReports.Wizards3
  [Expand]DevExpress.XtraReports.Wizards3.Presenters
  [Expand]DevExpress.XtraReports.Wizards3.Views
[Expand]Report Server
[Expand]Dashboard
[Expand]eXpressApp Framework
[Expand]CodeRush
[Expand]CodeRush Classic
[Expand]Cross-Platform Core Libraries
[Expand]Tools and Utilities
 End-User Documentation

BandCollection Class

A collection of Band objects.

Namespace:DevExpress.XtraReports.UI
Assembly:DevExpress.XtraReports.v17.2.dll

Expanded Syntax

Expanded Remarks

Use the Add and Remove methods to add or remove individual bands from the collection. You can also determine if a band is a member of the collection by passing the band to the Contains method. To get the index value of the band in the collection, pass this band to the IndexOf method.

Expanded Example

The following example demonstrates how to use the basic methods of the BandCollection class to construct a simple report. The first method (AddMarginBands) creates two margin bands, and adds them to the report's collection of bands. The second method (RemoveMarginBands) removes margin bands from the collection.

Show Me

A complete sample project is available in the DevExpress Code Examples database at http://www.devexpress.com/example=E86.

And, the following code should be used to call these two methods:

Expanded Inheritance Hierarchy

System.Object
    System.Collections.CollectionBase
       XRControlCollectionBase
          XRControlCollection
             BandCollection
                DetailReportBandCollection

Expanded See Also

Is this topic helpful?​​​​​​​