I have configured the HTML5 viewer to display a report and I receive the following error message:
There was an error while loading the report ../Reports/ElementList.igr. Details: The Xml namespace 'http://schemas.infragistics.com/xaml/reports' could not be loaded. See inner exception for details.
This is an MVC (.aspx engine) CLR 4.0 web application. IG Reporting 12.2.20122.1014. (I am not using Silverlight.) Why am I seeing this message and how do I remove it and correctly display the report?
The declaration for my HTML5 viewer follows:
<%@ Page Title="" Language="C#" MasterPageFile="~/Main.master" AutoEventWireup="true" CodeBehind="sdsReportViewer.aspx.cs" Inherits="WebApp.Reports.SdsReportViewer" %><asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server"> <link href="../Styles/themes/base/jquery-ui.css" rel="stylesheet" /><link href="../Styles/themes/base/jquery.ui.core.css" rel="stylesheet" /><link href="../Styles/themes/base/jquery.ui.button.css" rel="stylesheet" /><link href="../Styles/themes/base/jquery.ui.dialog.css" rel="stylesheet" /><link href="../Styles/themes/base/jquery.ui.theme.css" rel="stylesheet" /><link href="../scripts/css/structure/jquery-ui-1.9.1.custom.min.css" rel="stylesheet" /> <link href="../scripts/themes/infragistics/infragistics.theme.css" rel="stylesheet" type="text/css" />
<script src="../scripts/igReports/modernizr-2.6.2.js" type="text/javascript"></script><script src="../scripts/jquery-1.8.2.min.js" type="text/javascript"></script><script src="../scripts/igReports/jquery-ui-1.9.0.min.js" type="text/javascript"></script> </asp:Content><asp:Content ID="Content5" ContentPlaceHolderID="PageHeaderContentPlaceHolder" runat="server"></asp:Content><asp:Content ID="Content6" ContentPlaceHolderID="SideBarPlaceHolder" runat="server"></asp:Content><asp:Content ID="Content7" ContentPlaceHolderID="PageContentPlaceHolder" runat="server"><script src="../scripts/infragistics.loader.js" type="text/javascript"></script><script type="text/javascript"> jQuery.ig.loader({ cssPath: '../css', scriptPath: '../Scripts', resources: 'igReportViewer', locale: '<%= System.Threading.Thread.CurrentThread.CurrentUICulture.Name.Substring(0,2) %>', ready: function () { //Page and resources are already loaded $("#viewer").igReportViewer({ renderSettings: { definitionUri: document.getElementById("<%= ReportName.ClientID %>").value, serviceEndpointUri: "../ReportService.svc/ajaxAddress/" } }); } });</script> <div id="viewer"></div> <asp:HiddenField ID="ReportName" runat="server" Value="" /></asp:Content>
When the form opens it picks up the report name from the QueryString and parks it in the "ReportName" hidden field. The report viewer uses this to identify the required report to display. This logic all seems to work OK. (I have tried putting a literal string for the report name and I get identical behaviour.). There are no missing .js or .css files. Reports are compiled using the default options (Embedded Resource).
Kind regards,
Paul
Hi Paul,
What does your web.config look like? What dlls is it referencing? That error makes it sound like it doesn't have the appropriate reporting dlls loaded where that namespace would be located.
Hi Rob,
Thanks for replying. Here it is:
<?xml version="1.0"?><!-- Note: As an alternative to hand editing this file you can use the web admin tool to configure settings for your application. Use the Website->Asp.Net Configuration option in Visual Studio. A full list of settings and comments can be found in machine.config.comments usually located in \Windows\Microsoft.Net\Framework\v2.x\Config --><configuration> <configSections> <section name="infragistics.web" type="System.Configuration.SingleTagSectionHandler,System, Version=1.0.3300.0, Culture=neutral, PublicKeyToken=b77a5c561934e089"/> <section name="ActiveReports7" type="GrapeCity.ActiveReports.Web.ActiveReportsSettingsSection"/> </configSections> <infragistics.web enableAppStyling="true" styleSetName="Appletini" styleSetPath="~/ig_res/"/> <appSettings> <add key="ChartImageHandler" value="storage=file;timeout=20;dir=c:\TempImageFiles\;"/> <add key="DataDynamicsARLic" value="John Rothwell,Mott MacDonald,DD-APN-30-C002284,74EOF444SSHFJHUF7M4H"/> <add key="ApplicationRoot" value="http://www.sds-online.biz/bordello/"/> <add key="ProgramVersion" value="1.1.001"/> <add key="ProgramReleaseDate" value="23rd October 2012"/> <add key="CookieEncryptionKey" value="{02CB9382-64DE-493D-8C59-19DC15D7FC30}"/> <add key="URLEncryptionKey" value="{02CB9382-64DE-493D-8C59-19DC15D7FC30}"/> </appSettings> <connectionStrings> <add name="SDS" connectionString="Data Source=.\SDS2012;Initial Catalog=xxxx;Integrated Security=True;" providerName="System.Data.SqlClient"/> <add name="OLE" connectionString="Provider=SQLOLEDB.1;Data Source=.\SQL2012;Initial Catalog=BRL7;Persist Security Info=True;User ID=xxxx;Password=xxxx;"/> <add name="LNQ" connectionString="Data Source=.\SQL2012;Initial Catalog=xxxx;Integrated Security=True;" providerName="System.Data.SqlClient"/> </connectionStrings> <system.web> <globalization culture="en-GB" uiCulture="en-GB" fileEncoding="utf-8"/> <!-- Set compilation debug="true" to insert debugging symbols into the compiled page. Because this affects performance, set this value to true only during development. --> <compilation debug="true" targetFramework="4.0"> <assemblies> <add assembly="System.Web.Extensions.Design, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/> <add assembly="System.Design, Version=4.0.0.0, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A"/> <add assembly="System.Transactions, Version=4.0.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089"/> <add assembly="Microsoft.ReportViewer.Common, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"/> <add assembly="Microsoft.ReportViewer.WebForms, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"/> <add assembly="System.Web.DataVisualization, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/> <add assembly="GrapeCity.ActiveAnalysis.Extensions, Version=2.1.827.0, Culture=neutral, PublicKeyToken=D557F2F30A260DA2"/> <add assembly="GrapeCity.ActiveAnalysis.Web, Version=2.1.827.0, Culture=neutral, PublicKeyToken=D557F2F30A260DA2"/> <add assembly="GrapeCity.ActiveReports.Web.v7, Version=7.0.5341.0, Culture=neutral, PublicKeyToken=CC4967777C49A3FF"/> <add assembly="GrapeCity.ActiveReports.Export.Document.v7, Version=7.0.5341.0, Culture=neutral, PublicKeyToken=CC4967777C49A3FF"/> <add assembly="GrapeCity.ActiveReports.Export.Pdf.v7, Version=7.0.5341.0, Culture=neutral, PublicKeyToken=CC4967777C49A3FF"/> <add assembly="GrapeCity.ActiveReports.Export.Html.v7, Version=7.0.5341.0, Culture=neutral, PublicKeyToken=CC4967777C49A3FF"/> <add assembly="GrapeCity.ActiveReports.Export.Xml.v7, Version=7.0.5341.0, Culture=neutral, PublicKeyToken=CC4967777C49A3FF"/> <add assembly="GrapeCity.ActiveReports.Export.Xaml.v7, Version=7.0.5341.0, Culture=neutral, PublicKeyToken=CC4967777C49A3FF"/> <add assembly="GrapeCity.ActiveReports.Export.Excel.v7, Version=7.0.5341.0, Culture=neutral, PublicKeyToken=CC4967777C49A3FF"/> <add assembly="GrapeCity.ActiveReports.Export.Word.v7, Version=7.0.5341.0, Culture=neutral, PublicKeyToken=CC4967777C49A3FF"/> <add assembly="GrapeCity.ActiveReports.Export.Image.v7, Version=7.0.5341.0, Culture=neutral, PublicKeyToken=CC4967777C49A3FF"/> <add assembly="GrapeCity.ActiveReports.Export.Rdf.v7, Version=7.0.5341.0, Culture=neutral, PublicKeyToken=CC4967777C49A3FF"/> <add assembly="GrapeCity.ActiveReports.v7, Version=7.0.5341.0, Culture=neutral, PublicKeyToken=CC4967777C49A3FF"/> <add assembly="GrapeCity.ActiveReports.Document.v7, Version=7.0.5341.0, Culture=neutral, PublicKeyToken=CC4967777C49A3FF"/> <add assembly="GrapeCity.ActiveReports.Extensibility.v7, Version=7.0.5341.0, Culture=neutral, PublicKeyToken=CC4967777C49A3FF"/> <add assembly="Infragistics4.Web.v12.2, Version=12.2.20122.2014, Culture=neutral, PublicKeyToken=7DD5C3163F2CD0CB"/> <add assembly="Infragistics4.WebUI.Documents.Reports.v12.2, Version=12.2.20122.2014, Culture=neutral, PublicKeyToken=7DD5C3163F2CD0CB"/> <add assembly="Infragistics4.WebUI.Documents.Excel.v12.2, Version=12.2.20122.2014, Culture=neutral, PublicKeyToken=7DD5C3163F2CD0CB"/> <add assembly="Infragistics4.WebUI.Documents.Word.v12.2, Version=12.2.20122.2014, Culture=neutral, PublicKeyToken=7DD5C3163F2CD0CB"/> <add assembly="Infragistics4.WebUI.Documents.IO.v12.2, Version=12.2.20122.2014, Culture=neutral, PublicKeyToken=7DD5C3163F2CD0CB"/> </assemblies> <buildProviders> <add extension=".rdlc" type="Microsoft.Reporting.RdlBuildProvider, Microsoft.ReportViewer.WebForms, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"/> </buildProviders> </compilation> <!-- The <authentication> section enables configuration of the security authentication mode used by ASP.NET to identify an incoming user. --> <authentication mode="Windows"/> <siteMap defaultProvider="XmlSiteMapProvider" enabled="true"> <providers> <add name="XmlSiteMapProvider" type="System.Web.XmlSiteMapProvider" siteMapFile="Web.sitemap" securityTrimmingEnabled="true"/> </providers> </siteMap> <!-- The <customErrors> section enables configuration of what to do if/when an unhandled error occurs during the execution of a request. Specifically, it enables developers to configure html error pages to be displayed in place of a error stack trace.
<customErrors mode="RemoteOnly" defaultRedirect="GenericErrorPage.htm"> <error statusCode="403" redirect="NoAccess.htm" /> <error statusCode="404" redirect="FileNotFound.htm" /> </customErrors> --> <pages theme="SDS" controlRenderingCompatibilityVersion="3.5" clientIDMode="AutoID"> <controls> <!--Data Aquarium Framework and AjaxControlToolkit references--> <add tagPrefix="act" namespace="AjaxControlToolkit" assembly="AjaxControlToolkit"/> <add tagPrefix="act" namespace="AjaxControlToolkit.HTMLEditor" assembly="AjaxControlToolkit"/> <add tagPrefix="aquarium" namespace="SDS.Web" assembly="SDS"/> <add tagPrefix="asp" namespace="System.Web.UI.DataVisualization.Charting" assembly="System.Web.DataVisualization, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35"/> </controls> </pages> <httpHandlers> <add path="*.xml" verb="*" type="System.Web.HttpForbiddenHandler" /> <add path="Reserved.ReportViewerWebControl.axd" verb="*" type="Microsoft.Reporting.WebForms.HttpHandler, Microsoft.ReportViewer.WebForms, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" validate="false" /> <add path="Blob.ashx" verb="*" type="SDS.Handlers.Blob" validate="false" /> <add path="Export.ashx" verb="*" type="SDS.Handlers.Export" validate="false" /> <add path="Import.ashx" verb="*" type="SDS.Handlers.Import" validate="false" /> <add path="Details.aspx" verb="*" type="SDS.Handlers.Details" validate="false" /> <add path="Report.ashx" verb="*" type="SDS.Handlers.Report" validate="false" /> <add path="ControlHost.aspx" verb="*" type="SDS.Web.ControlHost" validate="false" /> <add path="ChartHost.aspx" verb="*" type="SDS.Web.ChartHost" validate="false" /> <add path="ChartImg.axd" verb="GET,HEAD,POST" type="System.Web.UI.DataVisualization.Charting.ChartHttpHandler, System.Web.DataVisualization, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" validate="false" /> <add path="*.rpx" verb="*" type="GrapeCity.ActiveReports.Web.Handlers.RpxHandler, GrapeCity.ActiveReports.Web.v7, Version=7.0.5341.0, Culture=neutral, PublicKeyToken=cc4967777c49a3ff" /> <add path="*.rdlx, *.rdl" verb="*" type="GrapeCity.ActiveReports.Web.Handlers.RdlxHandler, GrapeCity.ActiveReports.Web.v7, Version=7.0.5341.0, Culture=neutral, PublicKeyToken=cc4967777c49a3ff" /> <add path="*.ar7" verb="*" type="GrapeCity.ActiveReports.Web.Handlers.ReportBinariesStreamer, GrapeCity.ActiveReports.Web.v7, Version=7.0.5341.0, Culture=neutral, PublicKeyToken=cc4967777c49a3ff" /> <add path="*.ar7Web" verb="*" type="GrapeCity.ActiveReports.Web.Handlers.WebCacheAccessHandler, GrapeCity.ActiveReports.Web.v7, Version=7.0.5341.0, Culture=neutral, PublicKeyToken=cc4967777c49a3ff" /> <add path="*.igrResource" verb="*" type="Infragistics.Reports.Server.ResourcesHandler, InfragisticsWPF4.Reports.Server.v12.2, Version=12.2.20122.1014, Culture=neutral, PublicKeyToken=7dd5c3163f2cd0cb" validate="false" /> </httpHandlers> <httpModules> <add name="ReportProcessorServiceModule" type="Infragistics.Reports.Server.ReportProcessorServiceModule, InfragisticsWPF4.Reports.Server.v12.2, Version=12.2.20122.1014, Culture=neutral, PublicKeyToken=7dd5c3163f2cd0cb" /> </httpModules> <webServices> <protocols> <remove name="Documentation"/> </protocols> </webServices> </system.web> <!-- The system.webServer section is required for running ASP.NET AJAX under Internet Information Services 7.x. It is not necessary for previous version of IIS. --> <system.webServer> <validation validateIntegratedModeConfiguration="false"/> <modules runAllManagedModulesForAllRequests="true"/> <handlers> <add name="All_XML" verb="*" path="*.xml" type="System.Web.HttpForbiddenHandler" resourceType="Unspecified"/> <add name="Reserved_ReportViewerWebControl_axd" path="Reserved.ReportViewerWebControl.axd" verb="*" type="Microsoft.Reporting.WebForms.HttpHandler, Microsoft.ReportViewer.WebForms, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" resourceType="Unspecified"/> <!--Data Aquarium Framework handlers--> <add name="Blob_ashx" verb="*" path="Blob.ashx" type="SDS.Handlers.Blob" resourceType="Unspecified"/> <add name="Export_ashx" verb="*" path="Export.ashx" type="SDS.Handlers.Export" resourceType="Unspecified"/> <add name="Import_ashx" verb="*" path="Import.ashx" type="SDS.Handlers.Import" resourceType="Unspecified"/> <add name="Details_aspx" verb="*" path="Details.aspx" type="SDS.Handlers.Details" resourceType="Unspecified"/> <add name="Report_ashx" verb="*" path="Report.ashx" type="SDS.Handlers.Report" resourceType="Unspecified"/> <add name="ControlHost_ashx" verb="*" path="ControlHost.aspx" type="SDS.Web.ControlHost" resourceType="Unspecified"/> <add name="ChartHost_ashx" verb="*" path="ChartHost.aspx" type="SDS.Web.ChartHost" resourceType="Unspecified"/> <remove name="ChartImageHandler"/> <add name="ChartImageHandler" preCondition="integratedMode" verb="GET,HEAD,POST" path="ChartImg.axd" type="System.Web.UI.DataVisualization.Charting.ChartHttpHandler, System.Web.DataVisualization, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35"/> <remove name="AR7"/> <remove name="AR7Rdl"/> <remove name="AR7Rdlx"/> <remove name="AR7Rpx"/> <remove name="AR7Web"/> <add name="AR7" path="*.ar7" verb="*" modules="IsapiModule" scriptProcessor="%windir%\Microsoft.NET\Framework64\v4.0.30319\aspnet_isapi.dll" preCondition="classicMode,runtimeVersion4.0,bitness64"/> <add name="AR7Rdl" path="*.rdl" verb="*" modules="IsapiModule" scriptProcessor="%windir%\Microsoft.NET\Framework64\v4.0.30319\aspnet_isapi.dll" preCondition="classicMode,runtimeVersion4.0,bitness64"/> <add name="AR7Rdlx" path="*.rdlx" verb="*" modules="IsapiModule" scriptProcessor="%windir%\Microsoft.NET\Framework64\v4.0.30319\aspnet_isapi.dll" preCondition="classicMode,runtimeVersion4.0,bitness64"/> <add name="AR7Rpx" path="*.rpx" verb="*" modules="IsapiModule" scriptProcessor="%windir%\Microsoft.NET\Framework64\v4.0.30319\aspnet_isapi.dll" preCondition="classicMode,runtimeVersion4.0,bitness64"/> <add name="AR7Web" path="*.ar7Web" verb="*" modules="IsapiModule" scriptProcessor="%windir%\Microsoft.NET\Framework64\v4.0.30319\aspnet_isapi.dll" preCondition="classicMode,runtimeVersion4.0,bitness64"/> </handlers> </system.webServer> <system.web.extensions> <scripting> <webServices> <jsonSerialization maxJsonLength="524288"/> </webServices> </scripting> </system.web.extensions> <system.serviceModel> <behaviors> <endpointBehaviors> <behavior name="SilverlightFaultBehavior"> <silverlightFaults /> </behavior> <behavior name="JsonFaultBehavior"> <enableWebScript /> <jsonFaults /> </behavior> </endpointBehaviors> <serviceBehaviors> <behavior name="ReportProcessorServiceBehavior"> <serviceMetadata httpGetEnabled="true" /> <serviceDebug includeExceptionDetailInFaults="false" /> </behavior> </serviceBehaviors> </behaviors> <bindings> <customBinding> <binding name="binaryHttpBinding"> <binaryMessageEncoding /> <httpTransport /> </binding> </customBinding> </bindings> <extensions> <behaviorExtensions> <add name="silverlightFaults" type="Infragistics.Reports.Server.SilverlightFaultBehavior, InfragisticsWPF4.Reports.Server.v12.2, Version=12.2.20122.1014, Culture=neutral, PublicKeyToken=7dd5c3163f2cd0cb" /> <add name="jsonFaults" type="Infragistics.Reports.Server.JsonErrorWebHttpBehaviorElement, InfragisticsWPF4.Reports.Server.v12.2, Version=12.2.20122.1014, Culture=neutral, PublicKeyToken=7dd5c3163f2cd0cb" /> </behaviorExtensions> </extensions> <serviceHostingEnvironment aspNetCompatibilityEnabled="true" /> <services> <service behaviorConfiguration="ReportProcessorServiceBehavior" name="Infragistics.Reports.Server.ReportProcessorService"> <endpoint address="soapAddress" behaviorConfiguration="SilverlightFaultBehavior" binding="customBinding" bindingConfiguration="binaryHttpBinding" contract="Infragistics.Reports.Server.IReportProcessorService"> <identity> <dns value="localhost" /> </identity> </endpoint> <endpoint address="ajaxAddress" behaviorConfiguration="JsonFaultBehavior" binding="webHttpBinding" contract="Infragistics.Reports.Server.IReportProcessorService" /> <endpoint address="mex" binding="mexHttpBinding" contract="IMetadataExchange" /> </service> </services> </system.serviceModel></configuration>
I'm attempting to migrate from ActiveReports7 which is a nightmare to configure with regard to the http handlers. Hopefully, once I have the IG reporting working ok I can get rid of a lot of crud from this file.