locked
Report Viewer not working on .Net Framework 4.0 RRS feed

  • Question

  • User-1298263675 posted
    Report Viewer does not work on a .NET Framework 4.0

    Once I provide Report Server and path details and run the application it fails with the error

    The Report Viewer Web Control HTTP Handler has not been registered in the application's web.config file.
    Add <add verb="*" path="Reserved.ReportViewerWebControl.axd" type = "Microsoft.Reporting.WebForms.HttpHandler, Microsoft.ReportViewer.WebForms, Version=11.0.0.0, Culture=neutral, PublicKeyToken=89845dcd8080cc91" /> to the system.web/httpHandlers section of the web.config file, or add <add name="ReportViewerWebControlHandler" preCondition="integratedMode" verb="*" path="Reserved.ReportViewerWebControl.axd" type="Microsoft.Reporting.WebForms.HttpHandler, Microsoft.ReportViewer.WebForms, Version=11.0.0.0, Culture=neutral, PublicKeyToken=89845dcd8080cc91" /> to the system.webServer/handlers section for Internet Information Services 7 or later.

    I have the same http handler information on the web.config and I have referenced the version 11 report viewer DLL to my application.

    I tried to replicate this scenario on .NET Framework 4.5 and 3.5. There it worked perfectly alright.

    Does anyone has a clue of what might be wrong ?
    Thursday, January 29, 2015 9:11 PM

Answers

  • User1711366110 posted

    Hi ,
      As per your case,
    In web.config file, you must define both an httphandlers element and a handlers element in the version10.0 like below :

    <configuration>
     <system.web>
      <httpHandlers>
        <add verb = "*" path = "Reserved.ReportViewerWebControl.axd" type = "Microsoft.Reporting.WebForms.HttpHandler,  Microsoft.ReportViewer.WebForms, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
      </httpHandlers>
     </system.web>
     <system.webServer>
       <add name = "ReportViewerWebControlHandler" preCondition = "integratedMode" verb = "*" path = "Reserved.ReportViewerWebControl.axd" type = "Microsoft.Reporting.WebForms.HttpHandler, Microsoft.ReportViewer.WebForms, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
     </system.webServer>
    </configuration>
    

    1. Click here to know more about Register httphandlers.

    2. Click here to know more about web.config with sample code having report viewer.

    --
    with regards,
    Edwin

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Friday, January 30, 2015 9:00 AM