ActiveReports 16 .NET Edition
ActiveReports 16 User Guide / Concepts / Section Report Concepts / Designing Code-based Section Reports in .NET Core
In This Topic
    Designing Code-based Section Reports in .NET Core
    In This Topic

    The existing limitation in .NET Core 3.1/.NET 5.0 does not allow the ActiveReports Integrated Designer to be used for designing Code-based Section Reports in WinForms applications in Visual Studio.
    As workaround, you need to use Visual Studio's option to link report files from .NET Core project in the .NET Framework project, and use the .NET Framework WinForms Designer.


    The steps to enable design-time report creation in .NET Core project for Code-Based Section reports are as follows:

    1. Create a new Windows Forms .NET Core project.

      Create a new project window

      Configure your new project dialog
    2. Select the Target Framework as 'NET 5.0' and select Create.
      Solution Explorer
    3. Add the code-based section report item to the .NET Core project. To do so, right-click the project and go to Add > New Item.

      Solution Explorer
    4. Select ActiveReports 16 Section Report (code-based) report item. All the required dependencies will be installed automatically.

      Add New Item dialog
    5. Add a new .NET Framework project using built-in Section Report (code-based) template.

      1. In the Solution Explorer, right-click the solution node and go to AddNew Project.

        Solution Explorer
      2. Select ActiveReports 16 Section Report Application (code-based) template and configure the project for the target .NET Framework version.

        Add a new project dialog

        Configure your new project dialog
    6. Remove the code-based report (SectionReport1.cs) from the .NET Framework project, which was added automatically in the previous step.

      section report moved to net core project
    7. Add report from the .NET Core project to the .NET Framework project as link.

      1. In the Solution Explorer, right-click the .NET Framework project, go to Add > Add Existing Item.
      2. Navigate to the .NET Core project and select report file: 'SectionReport1.cs'.
      3. Select Add As Link option to add the report files as link.
        Solution Explorer

        added section report

    8. Double-click the linked SectionReport1.cs (in .Net Framework project) to open the ActiveReports Integrated Designer for the report.

      added section report
    9. Now design the report. You will observe that the modification of a report in .NET Framework project leads to modification of the report in the .NET Core project.