I'm trying to use SSRS reporting with an Asp.net MVC website with local reports.
I tried everything that is mentioned in this post, but I keep getting a hidden div with the following message instead:
The Report Viewer Web Control HTTP Handler has not been registered in the application's web.config file. Add to the system.web/httpHandlers section of the web.config file, or add to the system.webServer/handlers section for Internet Information Services 7 or later.
The handlers are correctly added to the web config and reports will work if I navigate to the aspx page directly (by , but since view engine is not involved I cannot use any of razor helpers, this problem only occurs when I'm using routing.
I have RouteExistingFiles = false
and ignored the following routes:
{resource}.axd/{*pathInfo}; {resource}.aspx/{*pathInfo}; {resource}.ascx/{*pathInfo};
and disabled the BlockViewHandler
by removing it from the webconfig.
I'm using Microsoft.ReportViewer for visual studio 2012 (ver 11.0.0.0)
Edit There is this post from Scot Hanselman about using razor views with ASPX master pages, I'm doing the exact reverse, using aspx user control with Razor layout, but this Microsoft report viewer does not work with this approach.