When you add an ActiveReports 7 Section Report (code-based) to your Visual Studio project, report layouts are saved as C# or Visual Basic files within the project in which they are created. these files are compiled into the application when you build it. Each report is composed of three files:
- rptYourReportName.vb or .cs
- rptYourReportName.Designer.vb or .cs
- rptYourReportName.resx
In this way, layout information models the behavior of Windows Forms in the .NET framework.
The design surface of a section report has banded sections that repeat depending on the data and the type of section. For more information, see Section Report Structure and Section Report Events.
Code
This type of report is the most flexible in terms of what a .NET developer can achieve using code. It has an extensive API and is event-based, which allows you to control all aspects of the report and how it is generated. If you like, you can even build a report completely in code. See details about the API in the Class Library section of the help.
The API is also available with XML-based section reports, but you use VB or C# script instead of Windows Forms-like code. For more information, see XML-Based Section Report .
Data
Code-based section reports connect to data either via settings that you specify in the Report Data Source dialog, or through code. You can find more information on all of the ways to connect to data in a section report in the Work with Data in Section Reports topic.
Viewing and Exporting
To display a code-based report in the viewer, you use the LoadDocument method of the viewer. See Viewing Reports for more information. To export a code-based report, you use the Export method of the export you choose. For more information, see Export a Section Report.