A Cross-Tab Report represents information in cross-tabular form. A cross table (or pivot table) is similar to a simple plain data-bound table, but instead represents multi-dimensional hierarchical information in a single table with automatic sort, count, totals and grand totals for each row and column.
If you want to create a Cross-Tab Report, we recommend you to note the following best practices.
Use the XRPivotGrid control to create a pivot table inside a report. For example, if you want only a single pivot table to be present in a report, simply drop the XRPivotGrid control onto the Detail band.
To provide data for the XRPivotGrid control, assign the required datasource instance to its XRPivotGrid.DataSource property. Ensure that the XtraReportBase.DataSource property of your root report is not assigned; otherwise a report's Detail Band will be printed as many times as there are rows in this datasource.
Then, choose which of its XRPivotGrid.Fields should display values in a Row, Column or Data area. Note that the best way to manipulate pivot fields at design time is to invoke the Pivot Grid Designer, as shown in the following image.
Don't forget to add all required assemblies (e.g. DevExpress.XtraPivotGrid.v11.2.dll and DevExpress.PivotGrid.v11.2.Core.dll) to theReferences list of your project. To see the full list of required assemblies, refer to Windows Forms Deployment.
If you deploy your application on a web host that supports only a Medium Trust permission level, reports with XRPivotGrid controls will not work. For more information on this, refer to Medium Trust Support.
Below is an example of a typical Cross-Tab Report.