ArcGIS Pro 2.8 API Reference Guide
CreateReport(String,ReportDataSource,CIMPage,IEnumerable<ReportFieldStatistic>,ReportTemplate,String) Method

ArcGIS.Desktop.Reports Namespace > ReportFactory Class > CreateReport Method : CreateReport(String,ReportDataSource,CIMPage,IEnumerable<ReportFieldStatistic>,ReportTemplate,String) Method
The name of the report.
ReportDataSource object defining data source, fields, and definition query for the report.
The CIMPage definition for the report.
An array of T:ArcGIS.Desktop.Reports.ReportFieldStatistic that includes the statistics that will be used in the footer sections.
The report template.
The name of the report styling.
Creates a new report and adds it to a project. The source data for the report can be either a Layer or Table or a data connection to the data. This method must be called on the MCT. Use QueuedTask.Run.
Syntax

Parameters

name
The name of the report.
reportDataSource
ReportDataSource object defining data source, fields, and definition query for the report.
page
The CIMPage definition for the report.
statistics
An array of T:ArcGIS.Desktop.Reports.ReportFieldStatistic that includes the statistics that will be used in the footer sections.
template
The report template.
styling
The name of the report styling.

Return Value

The created report.
Exceptions
ExceptionDescription
This method or property must be called within the lambda passed to QueuedTask.Run.
reportDataSource
Must provide valid page with units defined.
Grouping template specified but no group field defined.
Group field defined for a non-grouping template.
Requirements

Target Platforms: Windows 10, Windows 8.1

See Also

Reference

ReportFactory Class
ReportFactory Members
Overload List