ActiveReports 18 .NET Edition
In This Topic
    Troubleshooting
    In This Topic

    If you run into an issue while using ActiveReports, you will probably find the solution within this section. Click any short description below to drop down the symptoms, cause, and solution. Or click a link to another section of the troubleshooting guide.

    General Troubleshooting

    The missing Microsoft.SqlServer.Types assembly may cause the query execution failure in VQD

    Symptoms: The missing Microsoft.SqlServer.Types assembly may cause the invalid query error at executing a dataset in the Visual Query Designer.

    Cause: The missing Microsoft.SqlServer.Types assembly is required to execute the query.

    Solution: To resolve this problem, install the Microsoft.SqlServer.Types assembly manually.

    Compilation Error related to conflicting assembly/package versions

    Symptoms: Errors like - could not load file or assembly or one of its dependencies, or Found conflicts between different versions of the same dependent assembly appear on compiling.

    Cause: Due to inability of Visual Studio to resolve assembly versions on its own.

    Solution: To resolve this problem, add a binding redirect in your config file. You can quickly add a binding redirect by double-clicking on the error in Visual Studio.

    Example to add bindingRedirect to config file
    Copy Code
    <dependentAssembly>
      <assemblyIdentity name="someAssembly"
        publicKeyToken="tokenName"
        culture="neutral" />
      <bindingRedirect oldVersion="7.0.0.0" newVersion="8.0.0.0" />
    </dependentAssembly>
    

    Visual Studio 2017 fails to build a VB.NET project sample

    Symptoms: Visual Studio 2017 fails to build a VB.NET project sample with the following error:

    Error BC30284 You cannot declare sub'OnCreateMainForm' as'Overrides' because you do not override sub in the base class.

    Cause: Visual Studio 2017 does not fully support WinForms in VB.NET projects that use Microsoft.NET.Sdk.

    Solution: To resolve this issue, you can do either of the following:

    1. Use Visual Studio 2019 or above.
    2. Use legacy .csproj format without Microsoft.NET.Sdk.

    Error appears on exporting Page/RDLX reports from JSViewer run on ASP.NET Core MVC application

    Symptoms: "Export report error" appears on exporting Page/RDLX Report from JSViewer when run through ASP.NET Core MVC applications.

    Cause: ASP.NET Core MVC has undergone some changes that disable the synchronous server operations. See this for more information.

    Solution: Add following content in Startup.cs to turn on the synchronous operations.

    Startup.cs
    Copy Code
    services.Configure<IISServerOptions>(options =>
    {
        options.AllowSynchronousIO = true;
    });
    

    Error appears on using parameterized queries with OLE DB provider in .NET core applications

    Symptoms: Error is thrown on using parameterized queries with OLE DB provider in .NET Core applications.

    Cause: The number of query parameters specified in the dataset do not match the parameters used in the SQL query for dataset. Note that this works perfectly well for  OLE DB provider from Full .NET Framework.

    Solution: The number of query parameters specified in the SQL query should be same as number of query parameters in dataset.

    Report menu does not appear in the main menu of Visual Studio 2019 or Visual Studio 2022

    Symptoms: When a report is opened in Visual Studio 2019 or Visual Studio 2022, Report menu does not appear in the main menu.

    Cause: Due to new behavior relating to extensions, Report menu is removed as main menu.

    Solution: Go to Extensions menu. You can see that the Report menu is available as submenu.

    References missing from Visual Studio Add Reference dialog

    Symptoms: When you try to add references to your project, only a few of the ActiveReports references are available.

    Cause: The project's target framework is set to an old version of the .NET framework that does not support the new assemblies.

    Solution:

    1. In the Solution Explorer, right click the project and choose Properties.
    2. On the Application tab in C# projects (or the Compile tab, then the Advanced Compile Options button in Visual Basic projects), drop down the Target framework box and select .NET Framework 4.6.2.

    Errors after installing a new build

    Symptoms: When you open a project created with a previous build of ActiveReports after installing a new build, there are errors related to being unable to find the previous build.

    Cause: Visual Studio has a property on references called Specific Version. If this property is set to True, the project looks for the specific version that you had installed when you created the report, and throws errors when it cannot find it.

    Solution: For each of the ActiveReports references in the Solution Explorer, select the reference and change the Specific Version property to False in the Properties Panel.

    An Exception occurs on previewing reports connecting Microsoft Access OLE DB provider in a 64-bit system

    Symptoms: "System.InvalidOperationException: The 'Microsoft.Jet.OLEDB.4.0' provider is not registered on the local machine." occurs on previewing reports connecting to Microsoft.Jet.OLEDB.4.0 provider on a 64-bit operating system.

    Cause: The Microsoft Access OLE DB provider, Microsoft.Jet.OLEDB.4.0, is not compatible with 64 bit, so it fails on a 64-bit operating systems.

    Solution: To avoid this, you have two options.

    1. (Preferred) Change the OLE DB Provider to Microsoft.ACE.OLEDB.12.0.

    Note that both 32-bit and 64-bit version of Microsoft.ACE.OLEDB.12.0 should be available in your machine.

    2. Change the project settings to use only 32 bit.

    1. With the project open in Visual Studio, from the Project menu, select Project Properties.
    2. In the page that appears, select the Compile tab in a VB project, or the Build tab in a C# project.
    3. Scroll to the bottom of the page and click the Advanced Compile Options button in VB, or skip this step in C#.
    4. Drop down the Target CPU list in VB, or Platform target in C#, (set to use AnyCPU by default) and select x86.
    5. Click OK to save the changes, or skip this step in C#.

    The printing thread dies before the report finishes printing

    Symptoms: The printing thread dies before the report is printed.

    Cause: If printing is done in a separate thread and the application is shut down right after the print call, the separate thread dies before the report is printed.

    Solution: Set the usePrintingThread parameter of the Print() method to False to keep the printing on the same thread. This applies to all Page reports, RDLX reports and Section Reports.

    1. In the project where you call the Print method, add a reference to the MESCIUS.ActiveReports.Viewer.Win package.
    2. At the top of the code file where you call the Print method, add a using directive (Imports for VB) for GrapeCity.ActiveReports.
    3. Call the Print method with the usePrintingThread parameter (the third parameter) set to false with code like the following.
    C# code.
    Copy Code
    document.Print(false, false, false);
    
    Visual Basic code.
    Copy Code
    document.Print(False, False, False)
    

    Exception thrown when using Viewer.Print to print a report

    Symptoms: An exception is thrown when the Viewer.Print method is used to print a report.

    Cause: Print method was called before the page was loaded completely.

    Solution: Use the Viewer.Print method in the LoadCompleted event.

    Code generation error appears with code-based report applications

    Symptoms: The Code generation error appears when working with a code-based application in Visual Studio.

    Cause: This is because of the cache problems in Visual Studio 2019 and Visual Studio 2022.

    Solution: Use one of the solutions described below.

    • Clean Visual Studio cache.
      • Remove the folder C:\Users\[user name]\AppData\Local\Microsoft\VisualStudio\[VS version dir]\ProjectAssemblies.
    • Reset Visual Studio settings (see here for more details). For example, in Visual Studio,
      1. Open cmd.
      2. Switch to C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\Common7\IDE folder.
      3. Run devenv/resetsettings.
      The Visual Studio settings reset may result in the loss of important data.

    Timeout error appears on running Angular(Core) samples for WebDesigner and JSViewer with default settings

    Symptoms: The timeout error sometimes appears when running the WebDesigner_Angular(Core) and JSViewer_Angular(Core) samples with default settings. See Web Samples for more information.

    Cause: The connection timeout period is not sufficient and must be increased.

    Solution: To increase the solution timeout period, add the following code to the Startup.cs file.

        if (env.IsDevelopment())

         {

         spa.UseAngularCliServer(npmScript: "start");

         spa.Options.StartupTimeout = TimeSpan.FromSeconds(200); //timeout

         }

    System.NotSupportedException occurs on previewing reports with scripts in Windows Forms Viewer or WPF Viewer in the .NET Core desktop applications

    Symptoms: When you preview  reports using Windows Forms Viewer, WPF Viewer, and Windows Designer components in .NET Core applications, the exception "System.NotSupportedException. No data is available for encoding 1252" occurs. For information on defining a custom encoding, see the documentation for the Encoding.RegisterProvider method.

    Cause: You need to register encodings before using .NET Core applications with Windows Forms Viewer, WPF Viewer, and Windows Designer components.

    Solution: To avoid this situation, please do the following.

    1. Add the System.Text.Encoding.CodePages package from NuGet .
    2. Add Encoding.RegisterProvider to Program.cs.
      Copy Code
      static void Main()
      {
      System.Text.Encoding.RegisterProvider(System.Text.CodePagesEncodingProvider.Instance);Application.EnableVisualStyles();
      Application.SetCompatibleTextRenderingDefault(false);
      Application.Run(new DesignerForm());
      }                                                
      

    An exception appears when using a relative path in the connection string in Linux

    Symptoms: When you run a project in Linux, an exception appears on rendering a report in Linux, but the same works correctly in Windows.

    Cause: This may occur when the connection string uses slash other than forward '/' slash.

    Solution: In the connection strings with a relative path to the reports, always use forward slash '/' for the report to render correctly across all platforms.

    SqlException appears with the message like "The certificate chain was issued by an authority that is not trusted"

    Symptoms: The SqlException with the message like "The certificate chain was issued by an authority that is not trusted" appears.

    Cause: This error occurs because the default behavior of client drivers was changed. Now the new driver tries to validate the server's certificate and fails if the certificate is not installed. See The certificate chain was issued by an authority that isn't trusted for details.

    Solution: Install the required certificate or use one of the following workarounds.

    1. Update the connection string. Add the TrustServerCertificate=True setting to the data source connection string.
      Example: “Data Source=20.186.17.78;Initial Catalog=Northwind;User ID=qatester;Password=qatesting;TrustServerCertificate=True
    2. Rollback to the old System.Data.SqlClient
      1. Configure a required MSSQL data provider in the ActiveReports.config file.
        ActiveReports.config file
        Copy Code
        <Configuration>
            <Extensions>
                <Data>
                    <Extension Name="SQL" Type="System.Data.SqlClient.SqlClientFactory, System.Data.SqlClient" DisplayName="Microsoft SQL Server" />
                </Data>
            </Extensions>
        </Configuration>
        
      2. Reference the System.Data.SqlClient NuGet package.

    Section Report Troubleshooting

    Warning related to conflicting assemblies when working with code-based section reports

    Symptoms: Visual Studio throws some warnings related to conflicting assemblies when creating projects from our code-based section report templates, or when adding code-based reports to existing projects.

    • Found conflicts between different versions of 'System.Runtime.CompilerServices.Unsafe' that could not be resolved.
    • Found conflicts between different versions of 'Microsoft.Bcl.AsyncInterfaces' that could not be resolved.

    Cause: Due to dependency on different versions of VS SDK required by MESCIUS.ActiveReports.Serializer.VS2022.dll and VS2022. See about MSBuild3277 in article and discussion.

    Solution: 

    • In case of C# projects, add the following tag to project properties to suppress the warning:
    Add following tag in .csproj
    Copy Code
    <Project ToolsVersion="4.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
      <PropertyGroup>
         ...
        <NoWarn>MSB3277</NoWarn>
         ...
      </PropertyGroup>
    
    • Update System.Runtime.CompilerServices.Unsafe and Microsoft.Bcl.AsyncInterfaces to version requested by Visual Studio (6.0.0).

    Blank pages printed between pages, or a red line appears in the viewer

    Symptoms: Blank pages are printed between pages of the report.

    Cause: This problem occurs when the PrintWidth plus the left and right margins exceeds the paper width. For example, if the paper size were set to A4, the PrintWidth plus the left and right margins cannot exceed 8.27"; otherwise blank pages will be printed. At run time, ActiveReports marks a page overflow by displaying a red line in the viewer at the position in which the breach has occurred.

    Solution: Adjust the PrintWidth in the report designer using either the property grid or by dragging the right edge of the report. Adjust page margins, height, and width either through the print properties dialog box (in the Report menu under Settings), or programmatically in the Report_Start event.

    Copying reports results in stacked controls

    Symptoms: A report file copied into a new project has all of its controls piled up at location 0, 0.

    Cause: The report has become disconnected from its resource file. When you set a report"s Localizable property to True, the Size and Location properties of the report"s controls are moved to the associated *.resx file, so if you copy or move the report, you must move the *.resx file along with it.

    Solution: When you copy a report"s *.vb or *.cs file from one project's App_Code folder into the App_Code folder of a new project, you need to also copy its *.resx file from the original project"s App_GlobalResources folder into the new project's App_GlobalResources folder.

    No data appears in a report containing the OleObject control

    Symptoms: No data appears in a report containing the OleObject control.

    Cause: This issue occurs when the Microsoft .NET Framework 4.6.2 or above is used and the useLegacyV2RuntimeActivationPolicy attribute is not set to True.

    Solution: Open the app.config file and set the useLegacyV2RuntimeActivationPolicy attribute to true.

    XML code. Paste INSIDE the app.config file.
    Copy Code
    <configuration>
    <startup useLegacyV2RuntimeActivationPolicy="true">
    <supportedRuntime version="MyRunTimeVersion"/>
    </startup>
    </configuration>
    

    An error message appears in the Fields list

    Symptoms: An error message is displayed in the Fields list in the Report Explorer instead of the fields.

    Cause: This is an expected error if no default value is given for a parameter. If the field is a data type other than text, memo, or date/time in Access, the report still runs normally.

    Solution: To display the fields in the Fields list in the Report Explorer, supply a default value for the parameter in the Properties Panel, or in the SQL query as below:

    SQL Query
    Copy Code
    <%Name | PromptString | DefaultValue | DataType | PromptUser%>
    

    Only the Name parameter is required. To use some, but not all, of the optional parameters, use all of the separator characters but with no text between one and the next for unused parameters. For example:

    SQL Query
    Copy Code
    <%Name | | DefaultValue | |%>
    

    An unhandled exception of type "System.Data..." occurs when the report is run

    Symptoms: When the report is run, an exception like the following occurs: "An unhandled exception of type "System.Data.OleDb.OleDbException" occurred in system.data.dll"

    Cause: If the field is a text, memo, or date/time data type in Access, the parameter syntax requires single quotes for text or memo fields, or pound signs for date/time fields. Please note that for different data sources, these requirements may differ.

    Solution: To avoid the exception when the report is run against an Access database, use pound signs for date/time values, or single quotes for string values in your SQL query, for example:

    SQL Query
    Copy Code
    #<%InvoiceDate | Choose invoice date: | 11/2/04 | D | True%>#
    

    or

    SQL Query
    Copy Code
    "<%Country | Country: | Germany | S | True%>"
    

    User is prompted for parameters for subreports even though they are supplied by the main report

    Symptoms: The parameter user interface pops up at run time asking for a value even though the main report is supplying the parameter values for the subreports.

    Cause: The default value of the ShowParameterUI property of the report is True.

    Solution: Set the ShowParameterUI property of the report to False. This can be done in the property grid or in code in the ReportStart event.

    The viewer shows the report on the wrong paper size

    Symptoms: In the viewer, the report renders to a different paper size than the one specified.

    Cause: ActiveReports polls the printer driver assigned to the report to check for clipping, margins, and paper sizes supported by the printer. If the paper size specified for the report is not supported by the printer, ActiveReports uses the printer's default paper size to render the report.

    Solution: If the report is to be printed, the printer assigned to the report must support the paper size and margins. Please note that any changes to the print settings in code must be made in or before the ReportStart event. To use custom paper sizes not supported by the driver, set the PrinterName to an empty string to use the ActiveReports virtual print driver. This does not allow printing, but is recommended for reports that are only exported or viewed. This prevents ActiveReports from making a call to the default printer driver. Use the following code in the ReportStart event, or just before .Run is called.

    C# code. Paste INSIDE the ReportStart event.
    Copy Code
    this.Document.Printer.PrinterName = '';
    
    Visual Basic.NET code. Paste INSIDE the ReportStart event.
    Copy Code
    Me.Document.Printer.PrinterName = ''
    

    The PaperHeight and PaperWidth properties, which take a float value defined in inches, have no effect unless you set the PaperKind property to Custom. Here is some sample code which can be placed in the ReportStart event, or just before .Run.

    C# code. Paste INSIDE the ReportStart event.
    Copy Code
    this.PageSettings.PaperKind = Drawing.Printing.PaperKind.Custom;
    this.PageSettings.PaperHeight = 2; 
    //sets the height to two inches 
    this.PageSettings.PaperWidth = 4; 
    //sets the width to four inches
    
    Visual Basic.NET code. Paste INSIDE the ReportStart event.
    Copy Code
    Me.PageSettings.PaperKind = Drawing.Printing.PaperKind.Custom 
    Me.PageSettings.PaperHeight = 2 
    'sets the height to two inches 
    Me.PageSettings.PaperWidth = 4 
    'sets the width to four inches
    

    Custom paper sizes do not work

    Symptoms: Custom paper sizes do not work.

    Cause: You can create more than one custom paper size, so setting only the PaperKind property is not enough to create a custom paper size.

    Solution: In addition to setting the PaperKind property to Custom, you must also set the PaperName property to a unique string.

    An exception relating to System.Data.SqlClient occurs on previewing Section Reports in Windows Forms Viewer or WPF Viewer in the .NET Core 3.1 desktop application 

    Symptoms: The "Could not load file or assembly 'System.Data.SqlClient" exception occurs when you preview a Section Report in the Windows Forms Viewer or WPF Viewer in the .NET Core 3.1 desktop application. This exception also occurs when you design a Section Report in the Designer in the .NET Core 3.1 desktop application.

    Cause: This is a Microsoft compatibility issue.

    Solution: You need to manually add the Microsoft.Windows.Compatibility NuGet package. For more information, see this article.

    Page/RDLX Report Troubleshooting

    An expression containing a numeric field name does not display any data at run time.

    Symptoms: An expression containing a numeric field name does not display any data at runtime.

    Cause: Visual Basic syntax does not allow an identifier that begins with a number.

    i.e. =Fields!2004.Value

    Solution: Make the numeric field name a string.

    i.e. =Fields("2004").Value or, =Fields.Item("2004").Value

    DataSet field in PageHeader of an RDLX report

    Symptoms: Cannot set a dataset field (bound field) in the PageHeader of an RDLX report.

    Cause: ActiveReports is based on the RDLX 2005 specifications, therefore, referencing datasets in the PageHeader of an RDLX report is not supported.

    Solution: There is no direct way to add a DataField in a PageHeader, however, as a workaround you can create a hidden report parameter that is bound to your dataset and has the default value set to your expression. For example, ="*" & First(Fields!name.Value). You can then use this parameter in the page header.
    Alternatively, you can use a Page Report, which lets you place data fields anywhere on a page.

    Exception thrown when using Viewer.Document property

    Symptoms: An exception is raised when Viewer.Document is used with a Page Report or RDLX report.

    Cause: Document property is available for Section Reports only.

    WPF Viewer Troubleshooting

    Report is not previewed properly in WPF Viewer when DPI is set to 125% or higher

    Symptoms: A report is rendered on top of the WPF Viewer in the continuous mode on scrolling, when DPI is set to 125% or higher.

    Cause: This is a WPF continuous mode limitation.

    Solution: To resolve this problem, add the following code to the project.

    Add to the Viewer.LoadCompleted event
    Copy Code
    Viewer.LoadCompleted += (_, __) =>
    {
    Viewer.ViewType = GrapeCity.Viewer.Common.Model.ViewType.Continuous;
    };      
            
    

    Toolbox for WPF Viewer is missing from WPF Project

    Symptoms: The Toolbox for WPF Viewer does not appear in a new WPF project in Visual Studio on adding WPF package, MESCIUS.ActiveReports.Viewer.Wpf.

    Cause: It is a Visual Studio limitation where XAML Hot Reload does not work correctly.

    Solution: The XAML Hot Reload should be enabled. To enable the XAML Hot Reload, follow these steps.

    1. Go to Debug > Options > General.
    2. Select options Enable UI Debugging Tools for XAML and Enable XAML Hot Reload.
    3. Open MainWindow.xaml. The Toolbar should now display the WPF Viewer tab.

    See Troubleshooting XAML Hot Reload for more information.

    TargetInvocationException occurs when running the WPF browser application

    Symptoms: When running the WPF browser application, the TargetInvocationException occurs.

    Cause: The WPF browser application does not support Partial Trust.

    Solution: Make sure that the WPF browser application uses Full Trust. To do that, in the Visual Studio Project menu, go to YourProject Properties and on the Security tab, under EnableClickOnce security settings, select the option This is a full trust application.

    Design-time error appears on adding the WPF Viewer to the xaml page if the project is targeting .NET Core 3.1. 

    Symptoms: A design-time error appears on adding the WPF Viewer to the xaml page if the project is targeting .NET Core 3.1.

    Cause: This is the .NET limitation.

    Solution: To resolve this problem, add the Microsoft.Windows.Compatibility NuGet package to the project and then rebuild the project. 

    Memory Troubleshooting

    Note: According to Microsoft it is not necessary to call GC.Collect and it should be avoided. However, if calling GC.Collect reduces the memory leak, then this indicates that it is not a leak after all. A leak in managed code is caused by holding a reference to an object indefinitely. If ActiveReports is holding a reference to an object, then the object cannot be collected by the garbage collector.

    Symptoms: ActiveReports is consuming too much memory; CPU usage always goes to 100% when using ActiveReports.

    Cause: There are several reasons why too much memory may be consumed:

    The report is not being disposed of properly

    Cause: The report is not being disposed of properly. The incorrect syntax is as follows.

    C# code.
    Copy Code
    //Incorrect!                
    rpt.Dispose();
    rpt=null;
    
    Visual Basic code.
    Copy Code
    'Incorrect!
    rpt.Dispose()
    rpt=Nothing
    

    Solution: The correct syntax for disposing of a Section Report is as follows.

    C# code.
    Copy Code
    //Correct!
    rpt.Document.Dispose();
    rpt.Dispose();
    rpt=null;
    
    Visual Basic code.
    Copy Code
    'Correct!
    rpt.Document.Dispose()
    rpt.Dispose()
    rpt=Nothing
    

    Report never finishes processing

    Cause: In some cases, very large reports can consume so much memory that the report never finishes processing. Some of the things that can cause this include:

    1. Many non-repeating images, or a high resolution repeating image
    2. Instantiating a new instance of a subreport each time the format event of a section fires
    3. Using a lot of subreports instead of grouping with joins in the SQL query
    4. Pulling in all of the data when only a few fields are needed (e.g. Select * from db instead of Select First, Last, Address from db)

    Solution: In cases where the report is too large to run any other way, the CacheToDisk property may be set to True. This property should only be used when there is no other way to run the report to completion. Before resorting to this method, please see the Optimize Section Reports topic.

    Task manager indicates the current "working set" of the process

    Cause: If inflated memory usage is seen in the Task Manager it is not necessarily in use by the code. Task manager indicates the current "working set" of the process and, upon request, other processes can gain access to that memory. It is managed by the Operating System.

    Solution: For an example of some working set behavior anomalies (which are considered normal), create a WinForms application and run it. Look in Task Manager at the working set for that process (it should be several megabytes), then minimize and maximize the form and notice that the working set reclaims to <1MB. Obviously, the code was not using all that memory even though Task Manager showed that it was allocated to that process. Similarly, you'll see ASP.NET and other managed service processes continue to gradually grow their working set even though the managed code in that process is not using all of it. To see whether this is the case, try using the two lines of code below in a button Click event after running the project.

    System.Diagnostics.Process pc = System.Diagnostics.Process.GetCurrentProcess();
    pc.MaxWorkingSet = pc.MinWorkingSet;

    If that reclaims the memory then the Operating System trimmed the working set down to the minimum amount necessary and this indicates that the extra memory was not actually in use.

    Web Applications Troubleshooting

    Some locale issues occur when generating reports on Linux Docker

    Symptoms: When creating or using Docker images, locale-related problems such as missing fonts are discovered.

    Cause: Due to missing configuration or incorrectly configured locale for Linux.

    Solution: To avoid this problem, the invariant mode needs to be disabled, and the locale settings should be set explicitly in the Dockerfile from which the image is built when creating Docker images.

    To do this, specify the following lines explicitly :

    Add after the base layer in the Dockerfile
    Copy Code
    # Disable the invariant mode (set in base image)
    ENV DOTNET_SYSTEM_GLOBALIZATION_INVARIANT=false\
        # Set the locale
        LC_ALL=en_US.UTF-8 \
        LANG=en_US.UTF-8
    

    Chart and Image controls not showing in WebViewer in IIS

    Symptoms: The charts and images are broken in the report preview in Web Viewer.

    Cause: It is because IIS tries to search the physical files instead of handling the request in the back end.

    Solution: To resolve this problem, add the following in web.config file:

    Add to web.config file
    Copy Code
    <handlers>
          <add verb="*" path="/api/reporting/*" type="System.Web.Handlers.ScriptModule" name="nostaticfile" resourceType="Unspecified" preCondition="integratedMode" />
    </handlers>
    

     This tells the IIS to redirect to our specific handler all requests which starts from "api/reporting".  See WebViewer_ASP.NET_C# sample.

    Error appears on adding MESCIUS.ActiveReports.Web.Design.VS2022 package in Visual Studio 2022

    Symptoms: On installing MESCIUS.ActiveReports.Web.Design.VS2022 package, an error "Could not install this package. You are trying to install this package into a project that targets '.NETFramework=v4.7.1', but the package does not contain any assembly references or content files that are compatible with that framework."

    Cause: In Visual Studio 2022, MESCIUS.ActiveReports.Web.Design.VS2022 package is not supported for .NET applications targeting .NET Framework 4.7.1 or below.

    Solution: Change the target framework to .NET Framework 4.7.2, .NET Framework 4.8, or .NET Framework 4.8.1, and then try installing the package again. The package should be installed without any errors.

    PDF opens in a new window when an application contains the WebViewer

    Symptoms: When using Internet Explorer and Acrobat Reader to view a page containing a WebViewer in PDF mode, the resulting PDF always opens in a new window.

    Cause: Acrobat Reader is only available in a 32-bit version. When the 64-bit version of Internet Explorer is used, it opens up an instance of the 32-bit version of Internet Explorer so that the plug-in and the PDF can load, rendering the resulting PDF in a new window.

    Solution:

    • Install a PDF reader plug-in that is 64-bit compatible.
      OR
    • Use the 32-bit version of Internet Explorer.

    PlatformNotSupportedException occurs on using WebViewer, JSViewer, and WebDesigner

    Symptoms: PlatformNotSupportedException occurs in Web Applications using WebViewer, JSViewer, and WebDesigner in Classic Pipeline Mode.
    Cause: The WebViewer, JSViewer, and WebDesigner are supported only in the Integrated pipeline mode.
    Solution: Change the Application Pool mode as follows:

    1. Open IIS Manager.
    2. Go to Application Pools.
    3. Select the application pool where your app runs.
    4. Select Basic Settings.
    5. In the Edit Application Pool dialog, change the Managed Pipeline Mode to Integrated.

    The "Report not found" error occurs when a report name contains special symbols

    Symptoms: When you specify a report name with special symbols, e.g. webViewer.ReportName="Folder\Report.rdlx", you may get a "Report not found" error.

    Cause: Additional code needs to be added to the Web.config file to have the WebViewer use report names with the corresponding folders.

    Solution: Add the following code to the Web.config file.

    Paste inside the Web.config file
    Copy Code
    <system.web> 
    <httpRuntime requestPathInvalidCharacters="" requestValidationMode="2.0"/>
    <pages validateRequest="false"/>
    </system.web> 
    
    <system.webServer>
    <security>
    <requestFiltering allowDoubleEscaping="true"/>
    </security>
    </system.webServer>             
    

    The 'The type or namespace name 'Linq' does not exist in the namespace 'System'' error occurs when adding the WebViewer control in an ASP.NET Web Site project

    Symptoms: When you add the WebViewer control in an ASP.NET Web Site project, the 'The type or namespace name 'Linq' does not exist in the namespace 'System' error occurs.

    Cause: This is a known NuGet limitation.

    Solution: You should install or upgrade the Microsoft.CodeDom.Providers.DotNetCompilerPlatform NuGet package.

    "This application will be terminated because it was built without a license for PageReport" error occurs on deploying an application on Azure Functions Application.

    Symptoms: When you deploy an application in an Azure Functions application, error "This application will be terminated because it was built without a license for PageReport" occurs.

    Cause: This is because the application being deployed is not licensed properly.

    Solution: You should follow the steps provided in the Licensing Compiled Code topic for correctly licensing the application before deploying it to the Azure Functions application.

    The export file extension appears incorrect in Chrome while exporting using JSViewer in a reporting service hosted in an external application.

    Symptoms: When using JSViewer in a reporting service hosted in an external application to export a report, the export file extension for download appears as .rdlx (in Chrome) instead of the corresponding format extension.

    Cause: This issue occurs because of the restriction to access response headers when using Fetch API (which we use to download the exported file) over CORS.

    Solution: You should add the following line in your CORS policy:

    HttpContext.Current.Response.AddHeader("Access-Control-Expose-Headers", "Content-Disposition");