Xceed Grid for WinForms v4.3 Documentation
Getting started with reporting

Welcome to Xceed Grid for WinForms v4.3 > Basic Concepts > Getting started with reporting

Xceed Grid for WinForms provides a built-in reporting engine that generates reports from the data in Grid-enabled applications. End-users can also optionally configure the reports using the provided forms. 

Adding these capabilities to an application is extremely easy, taking as little as three lines of code to do so. For example, the following lines of code are all that are needed to let end-users take advantage of reports in an application:

VB.NET Copy Code

Imports Xceed.Grid.Reporting

Dim generateReport As New GenerateReportForm( Me.gridControl1 )
generateReport.ShowDialog()

C# Copy Code

using Xceed.Grid.Reporting;

GenerateReportForm generateReport = new GenerateReportForm( this.gridControl1 );
generateReport.ShowDialog();

Of course, the application must contain a properly configured GridControl with a data source set. 

The GenerateReportForm class represents a form that end-users can use to create and manage the styles of their report, choose the fields to be displayed in reports, and print, preview, and export reports. It is also possible to access Page Setup from the form. A second class, CustomizeReportStyleForm, is used to let end-users edit report styles. The source code (in C#) for both GenerateReportForm and CustomizeReportStyleForm is provided for developers who wish to modify these forms. 

See How to use GenerateReportForm and Using CustomizeReportStyleForm for details on these forms.

Report styles and report style sheets

In addition to using the forms provided with Xceed Grid for WinForms, the reporting capabilties in Xceed Grid for WinForms can be accessed programmatically in two complementary ways:

  1. Through ReportStyle properties, available on each Grid element. 

  2. Through the ReportStyleSheet class, which is accessible through the ReportStyleSheet property of the Report class.

For details, see Report styles and report style sheets.

Distribution

The reporting capabilities of Xceed Grid for WinForms are optional. Consequently, if you do not need these capabilities, you do not need to distribute Xceed.Grid.Reporting.dll and Xceed.Pdf.dll.