DetailBand() Constructor
In This Article
Initializes a new instance of the DetailBand class with the default settings.
Namespace: DevExpress.XtraReports.UI
Assembly: DevExpress.XtraReports.v24.2.dll
NuGet Package: DevExpress.Reporting.Core
#Declaration
#Example
The following example demonstrates how to add a control to the DetailBand instance, and then add this band to a report.
using System.Drawing;
using DevExpress.XtraReports.UI;
// ...
// Create a report.
XtraReport rep = new XtraReport();
// Create a DetailBand instance.
DetailBand detail = new DetailBand();
// Create an XRLabel control.
XRLabel label = new XRLabel();
// Set its background color.
label.BackColor = Color.DarkGreen;
// Add the label to the Detail band.
detail.Controls.Add(label);
// Add the Detail band to the report.
rep.Bands.Add(detail);
// Show the report's print preview.
rep.ShowPreview();
See Also