Last post Dec 12, 2011 07:48 PM by N_EvilScott
Nov 30, 2011 08:24 AM|Arch-Stalker|LINK
In short: Is it possible to run a local report in Visual Studio 2010 when you have to keep your framework at 2.0?
I ask this because the customer still has framework 2.0 on his server. The development project is in vs 2010 and I was supposed to make some reports on it. Naturally Microsoft.ReportViewer.WebForms 10.0 did not work with this set up, so I reverted it to
version 8.0. Everything was fine up to the point when I tried to actually open the report, at which point I got an error message :
An error occurred during local report processing. The definition of the report 'Main Report' is invalid. The report definition is not valid. Details: The report definition has an invalid target namespace 'http://schemas.microsoft.com/sqlserver/reporting/2008/01/reportdefinition'
which cannot be upgraded.
After googling about it I get the impression that the problem is the combination of local report, framework 2.0 and vs2010, but I found no instuctions (atleast any I could understand) on what to do about it. Can anyone enlighten me?
Dec 01, 2011 05:08 AM|Srikanth Kasturi|LINK
I have a question for you : When you said about reverting the version of reportviewer, did you make the changes in the corresponding aspx file of it ? and also the web.config file where you mention the version of report viewer ?
If yes, then you may look at your GAC(c:/windows/assembly) for that dll to be available, failing on which this wont run.
Please let me know the progress on this. !!
Dec 05, 2011 09:08 AM|Arch-Stalker|LINK
I took out the report viewer from the tools and then added it back making sure it was the 8.0 version. Then I added it to the asp.net page, letting VS add the "Register Assembly" line.
Ergo in the web code it says
<%@ Register Assembly="Microsoft.ReportViewer.WebForms, Version=22.214.171.124, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"
Namespace="Microsoft.Reporting.WebForms" TagPrefix="rsweb" %>
at the start and the actual viewer is called like this:
<asp:UpdatePanel ID="UpdatePanel1" runat="server">
<rsweb:ReportViewer ID="ReportViewerKarma" runat="server">
In the web.config VS has added these following lines:
<add path="Reserved.ReportViewerWebControl.axd" verb="*" type="Microsoft.Reporting.WebForms.HttpHandler, Microsoft.ReportViewer.WebForms, Version=126.96.36.199, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" validate="false"/>
<add assembly="Microsoft.ReportViewer.WebForms, Version=188.8.131.52, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A"/>
<add extension=".rdlc" type="Microsoft.Reporting.RdlBuildProvider, Microsoft.ReportViewer.Common, Version=184.108.40.206, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"/>
The DLL itself is present and available as I can use it just fine if I run it in an VS2005 project
Dec 12, 2011 07:48 PM|N_EvilScott|LINK
That error message is saying that the report you have is built on the SQL Server 2008 Schema, which is ReportViewer 2010.
ReportViewer 2008 was built against the SQL Server 2005 Schema only because SQL Server 2008 was not released yet when ReportViewer 2008 came out.
You will need to recreate your report using Visual Studio 2008. Visual Studio 2010 does not support the previous editting environment for 2005 schema reports, but will make you update them before it will even open them.
It has nothing to do with the framework. It's the report file itself. The actual markup of the file.