Sinoy Devassy
Sinoy Devassy

Reputation: 574

Report builder 3.0 with asp.net

I am using visual studio 2008 and report builder3.0. Created a report in report builder and trying to attach it with asp.net. But when i am running the application report doesn't load and showing an error

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.

I stucked on this issue.What is the procedures for attaching an sql report with an asp.net application ? Please assist. Thank you.

Upvotes: 1

Views: 1833

Answers (2)

Jim Lafler
Jim Lafler

Reputation: 96

I had a very similar issue. Just all of a sudden I could no longer build a VS2010 project that contained an .rdlc file. I wasn't converting any reports or using a report server, everything was local. I tried creating a brand new project and adding an empty new rdlc report and hit build and it wouldn't work. Just one day it stopped compiling and gave me the following error:

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.

Turns out the issue was my "C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v10.0\ReportingServices\Microsoft.ReportingServices.targets" file had somehow changed. The top of my file was:

<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
  <UsingTask TaskName="Microsoft.Reporting.RdlCompile" AssemblyName="Microsoft.ReportViewer.Common, Version=9.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"/>

And it should have been:

<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
  <UsingTask TaskName="Microsoft.Reporting.RdlCompile" AssemblyName="Microsoft.ReportViewer.WebForms, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"/>

I changed that one "Using Task" line in the file and everything builds again. REALLY frustrating and it ate up two days of my life.

Hoping posting this comment may help someone else in a similar situation.

Jim Lafler

Upvotes: 3

Dalex
Dalex

Reputation: 3625

As mentioned here:http://blogs.msdn.com/b/brianhartman/archive/2008/12/05/sql-server-2008-and-the-reportviewer-controls.aspx

Local Mode

Local mode is a different story. When using local mode with the VS 2005 or VS 2008 viewer controls, you are using the same report processing engine that was shipped with SQL Server 2005. This engine does not understand the new report definition schema and attempting to load a report created with one of the new SQL Server 2008 authoring tools will result in this error:

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.

Upvotes: 2

Related Questions