Showing posts with label reference. Show all posts
Showing posts with label reference. Show all posts

Friday, March 23, 2012

RS2005 web reference produces "C2234: Array of References illegal"

Hello,
I'm new to RS2005 and have begun going through the Tutorials in SQLServer 2005 Books Online. I'm currently attempting to add "reportingservices2005.asmx" as a web reference to my VS2003 C#.NET project and I keep getting this compile time error:

error C2234: 'Warnings' : arrays of references are illegal

How do I get rid of this compile time error? This error appears in the generated file representing the RS2005.wsdl. Aside from the generated web reference files the other files of the VS2003 C#.NET project are the default project files by the wizard.

Thanks in advance for the help
ZeroVerticalUpgrading to VS2005 C#.NET got rid of the error. I must have overlooked this requirement. I just upgraded to VS2005 C#.NET and everything works fine now.|||It shouldn't really be a requirement. Not sure why it is happening. You should file a bug on the feedback center.

Wednesday, March 21, 2012

RS2005 breaks my build: Version 2.0 is not a compatible version

Hi,

We've developed a RS DataExtension on RS2000, including a reference to Microsoft.ReportingServices.Interfaces.dll. Since I have installed RS 2005 on my machine, (we actually saw this issue first on our build server) the project no longer compiles. We get this error:

fatal error CS0009: Metadata file 'c:\Program Files\Microsoft SQL Server\90\SDK\Assemblies\Microsoft.ReportingServices.Interfaces.dll' could not be opened -- 'Version 2.0 is not a compatible version.'

The VS.NET 2003 project does include a '_references' directory, with the RS2000 version of the Microsoft.ReportingServices.Interfaces.dll (v8.0.1038.0) in it and the project file has a local reference like

<Reference
Name = "Microsoft.ReportingServices.Interfaces"
AssemblyName = "Microsoft.ReportingServices.Interfaces"
HintPath = "_references\Microsoft.ReportingServices.Interfaces.dll"
/>

So since installing RS 2005, it seems like the compiler is picking up the Microsoft.ReportingServices.Interfaces.dll from the GAC. On the build server (and confirmed by the installation on my dev box) RS 2005 installs this dll into the GAC. The compiler can only find this dll in the GAC, or is VS.NET doing tricky things here?

So my question is now, why ... ooooh why does the compiler pick up the wrong dll from the GAC and why ... ooooh why does it not pick up the explicit hintpath that is given in the project file.

Someone please tell me how to force the compiler to look at the correct dll/path.

If you want to build a data extension to be used with RS 2005, you have to use the .NET 2.0 C# compiler (or VS 2005) and your data extension has to reference the updated Microsoft.ReportingServices.Interfaces.dll that was installed by RS 2005.

The Interfaces.dll of RS 2005 is based on .NET 2.0 and cannot be used in a .NET 1.1 (VS 2003) project.

-- Robert

|||

Robert, yes, I understand that.

Indeed for the RS 2005 version of our Data Extension, we will use VS2005 and a reference to the RS 2005 version of the dll.

But, I'd still like to be able to compile the RS 2000 version of our Data Extension, using VS.NET 2003 and a reference to the RS 2000 version of the dll.

So problem is however that I have an existing data extension compiled against the RS 2000 version, which is being compiled using devenv (VS.NET 2003). This all worked until our sysadmin installed RS 2005 on the build server. Since RS 2005 has been installed, VS.NET 2003 always attempts to use the RS 2005 version of the dll's to compile the code, where as it should do as it states in the docs and use the RS 2000 version of the dll as specified in the references hintpath.

I have already build our data extension using csc (.NET v1.1) directly, which does seem to respect the references given to it. I suspect that the issue is more a VS.NET 2003 issue, resolving the dll reference incorrectly 1) from the GAC, 2) from the .NET 2.0 GAC, instead of taking the dll that has been copied in the project directory.

Rudi

|||

A new day, a new result.

Today the build on my machine does work.

I did install VS 2005 yesterday, maybe that 'magically' fixed the problem.

So we're installing VS 2005 on our build server aswell, hopefully that will solve the problem for us.

|||

Turned out that installing VS 2005 did NOT solve the problem.

The real solution exists in creating a *.csproj.user file with the ReferencePath set correctly. When running devenv from the command-line, it will pick up the *.csproj.user file and use the ReferencePath to locate the correct reference.

I was hoping to see (and test) the VS2003 SP1 this month, but this seems to be another 'longwait' program, it was first promised to be April 2006, then June 2006, but still not here: http://msdn.microsoft.com/vstudio/support/servicing/sp1_vs03/default.aspx

RS2005 breaks my build: Version 2.0 is not a compatible version

Hi,

We've developed a RS DataExtension on RS2000, including a reference to Microsoft.ReportingServices.Interfaces.dll. Since I have installed RS 2005 on my machine, (we actually saw this issue first on our build server) the project no longer compiles. We get this error:

fatal error CS0009: Metadata file 'c:\Program Files\Microsoft SQL Server\90\SDK\Assemblies\Microsoft.ReportingServices.Interfaces.dll' could not be opened -- 'Version 2.0 is not a compatible version.'

The VS.NET 2003 project does include a '_references' directory, with the RS2000 version of the Microsoft.ReportingServices.Interfaces.dll (v8.0.1038.0) in it and the project file has a local reference like

<Reference
Name = "Microsoft.ReportingServices.Interfaces"
AssemblyName = "Microsoft.ReportingServices.Interfaces"
HintPath = "_references\Microsoft.ReportingServices.Interfaces.dll"
/>

So since installing RS 2005, it seems like the compiler is picking up the Microsoft.ReportingServices.Interfaces.dll from the GAC. On the build server (and confirmed by the installation on my dev box) RS 2005 installs this dll into the GAC. The compiler can only find this dll in the GAC, or is VS.NET doing tricky things here?

So my question is now, why ... ooooh why does the compiler pick up the wrong dll from the GAC and why ... ooooh why does it not pick up the explicit hintpath that is given in the project file.

Someone please tell me how to force the compiler to look at the correct dll/path.

If you want to build a data extension to be used with RS 2005, you have to use the .NET 2.0 C# compiler (or VS 2005) and your data extension has to reference the updated Microsoft.ReportingServices.Interfaces.dll that was installed by RS 2005.

The Interfaces.dll of RS 2005 is based on .NET 2.0 and cannot be used in a .NET 1.1 (VS 2003) project.

-- Robert

|||

Robert, yes, I understand that.

Indeed for the RS 2005 version of our Data Extension, we will use VS2005 and a reference to the RS 2005 version of the dll.

But, I'd still like to be able to compile the RS 2000 version of our Data Extension, using VS.NET 2003 and a reference to the RS 2000 version of the dll.

So problem is however that I have an existing data extension compiled against the RS 2000 version, which is being compiled using devenv (VS.NET 2003). This all worked until our sysadmin installed RS 2005 on the build server. Since RS 2005 has been installed, VS.NET 2003 always attempts to use the RS 2005 version of the dll's to compile the code, where as it should do as it states in the docs and use the RS 2000 version of the dll as specified in the references hintpath.

I have already build our data extension using csc (.NET v1.1) directly, which does seem to respect the references given to it. I suspect that the issue is more a VS.NET 2003 issue, resolving the dll reference incorrectly 1) from the GAC, 2) from the .NET 2.0 GAC, instead of taking the dll that has been copied in the project directory.

Rudi

|||

A new day, a new result.

Today the build on my machine does work.

I did install VS 2005 yesterday, maybe that 'magically' fixed the problem.

So we're installing VS 2005 on our build server aswell, hopefully that will solve the problem for us.

|||

Turned out that installing VS 2005 did NOT solve the problem.

The real solution exists in creating a *.csproj.user file with the ReferencePath set correctly. When running devenv from the command-line, it will pick up the *.csproj.user file and use the ReferencePath to locate the correct reference.

I was hoping to see (and test) the VS2003 SP1 this month, but this seems to be another 'longwait' program, it was first promised to be April 2006, then June 2006, but still not here: http://msdn.microsoft.com/vstudio/support/servicing/sp1_vs03/default.aspx

Monday, March 12, 2012

RS Web Service Reference File

Where do I go to add a constractor of "this.Timeout=..." to a the Web Service
reference file?
Challenge: Long running reports are timing out
Thank you for your assistance.Find ReportingService() class in a reference file.
it looks like :
public class ReportingService :
System.Web.Services.Protocols.SoapHttpClientProtocol
{
.....
}
replace "public ReportingService() {...}" with
public ReportingService()
{
this.Timeout=1200000;
}
or you can even overload that constructor by adding the following
public ReportingService(string url)
{
this.Url = url;
this.Timeout=1200000;
}
do not regenerate it, otherwise you'll loose your changes.
another way is to extend ReportingService class.
"Terry" <Terry@.discussions.microsoft.com> wrote in message
news:76DCAFF8-F66B-4666-8C96-4A1817D13CD6@.microsoft.com...
> Where do I go to add a constractor of "this.Timeout=..." to a the Web
> Service
> reference file?
> Challenge: Long running reports are timing out
> Thank you for your assistance.
>
>|||Thank you very much!
"Oleg Yevteyev" wrote:
> Find ReportingService() class in a reference file.
> it looks like :
> public class ReportingService :
> System.Web.Services.Protocols.SoapHttpClientProtocol
> {
> ......
> }
> replace "public ReportingService() {...}" with
> public ReportingService()
> {
> this.Timeout=1200000;
> }
> or you can even overload that constructor by adding the following
> public ReportingService(string url)
> {
> this.Url = url;
> this.Timeout=1200000;
> }
> do not regenerate it, otherwise you'll loose your changes.
> another way is to extend ReportingService class.
>
> "Terry" <Terry@.discussions.microsoft.com> wrote in message
> news:76DCAFF8-F66B-4666-8C96-4A1817D13CD6@.microsoft.com...
> > Where do I go to add a constractor of "this.Timeout=..." to a the Web
> > Service
> > reference file?
> >
> > Challenge: Long running reports are timing out
> >
> > Thank you for your assistance.
> >
> >
> >
>
>