You can use the C1ReportDesigner to create report definition files (XML files that may contain one or more report definitions). For details on how to use the C1ReportDesigner, see the Working with C1ReportDesigner section of the documentation.
To load a report definition from a file at design time, complete one of the following tasks:
OR
Using the Select a report dialog box to select the report you want, complete the following tasks:
This is what the report selector dialog box looks like:
To load a report definition from a file, use the Load method. It takes as parameters the name of the report definition file and the name of the report you want to load. If you want to list the reports contained in a report definition file, use the GetReportInfo method. It returns a list of the reports in the file.
For example:
To write code in Visual Basic
Visual Basic |
Copy Code
|
---|---|
' Get list of reports in a report definition file Dim reports As String() = c1r.GetReportInfo(reportFile) ' Load first report into C1Report component c1r.Load(reportFile, reports(0)) |
To write code in C#
C# |
Copy Code
|
---|---|
// Get list of reports in a report definition file string[] reports = c1r.GetReportInfo(reportFile); // Load first report into C1Report component c1r.Load(reportFile, reports[0]); |