I have a web form containing a ReportViewer control, a DIV element so I can see that the page actually renders. I see that my page properly loads, I see the report service being accessed in Fiddler, but there is never anything displayed.
At present, I'm using a report with static text, no queries on it, in order to ensure that I isolate the issue.
My page is as follows:
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="ReportViewer.aspx.cs" Inherits="PeopleNet.Web.Views.Reports.ReportViewer" %>
<%@ Register Assembly="Microsoft.ReportViewer.WebForms, Version=11.0.0.0, Culture=neutral, PublicKeyToken=89845dcd8080cc91"
Namespace="Microsoft.Reporting.WebForms" TagPrefix="rsweb" %>
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
<title></title>
</head>
<body>
<form id="form1" runat="server">
<asp:ScriptManager ID="ScriptManager1" runat="server">
<Scripts>
<asp:ScriptReference Path="~/scripts/jquery-1.7.2.js" />
<asp:ScriptReference Path="~/scripts/fixReportViewer.js" />
</Scripts>
</asp:ScriptManager>
<div>
This is the report viewer page...
</div>
<rsweb:ReportViewer ID="ReportViewer1" runat="server"></rsweb:ReportViewer>
</form>
</body>
</html>
The code to display the report is:
protected void Page_Load(object sender, EventArgs e)
{
this.ReportViewer1.ServerReport.ReportServerUrl = ConfigurationFacade.ReportServerUri;
this.ReportViewer1.ServerReport.ReportPath = { path to report name };
this.ReportViewer1.ServerReport.ReportServerCredentials = new ReportServerCredentials(); // custom class implementing IReportServerCredentials as described in various places around the web, including SO
this.ReportViewer1.ServerReport.Refresh();
}
My web.config file is configured with the HttpHandlers as required:
<system.web>
<!-- abbreviated... -->
<httpHandlers>
<add path="Reserved.ReportViewerWebControl.axd" verb="*" type="Microsoft.Reporting.WebForms.HttpHandler, Microsoft.ReportViewer.WebForms, Version=11.0.0.0, Culture=neutral, PublicKeyToken=89845dcd8080cc91" validate="false" />
</httpHandlers>
</system.web>
And :
<system.webServer>
<!-- abbreviated... -->
<handlers>
<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" />
</handlers>
</system.webServer>
The server runs Windows 2008 and SQL Server 2008 R2.
I am using the SQL Server 2012 version of the viewer, as we are in the process of updating our environments to 2012.
I have repeatedly verified that the report is accessible from the ReportManager, with no issues whatsoever.
I have been attempting to access this in IE9, having seen various issues stated with other browsers.
I am presently (for testing only) passing my credentials as the report server credentials. I am a Reporting Services Administrator, as well as a member of the server administrators group on the server.
I have checked both the event log and the ReportServerService log, and have found nothing amiss.
UPDATE: Looks like when change the AsyncRendering to false, and ensure that I don't try to "SetParameters" with an empty collection, this gets mostly cleared up:
this.ReportViewer1.AsyncRendering = false;
What am I missing in the configuration/code here?
My solution to this issue was related to trying to set the report viewer height to 100%. This resulted in no report showing. Changing the height to a px value (ie 900px) got the reportviewer working.