I’m trying to set up a build machine and have managed to get everything up and running. This is the last bit I’m stuck on. I tried to un/reinstall ReportViewer 10, and also tried to install versions 8 and 9 to see if it would resolve the problem but with no success. Anyway here’s the error:
c:\Program Files\Microsoft Visual Studio 9.0\ReportViewer\Microsoft.ReportViewer.WinForms.dll: error CS1684:
Warning as Error: Reference to type Microsoft.ReportingServices.ReportProcessing.RenderingResult’ claims it is defined in ‘c:\
Program Files\Microsoft Visual Studio 10.0\ReportViewer\Microsoft.ReportViewer.
Common.dll’, but it could not be found
And similarly,
c:\Program Files\Microsoft Visual Studio 9.0\ReportViewer\Microsoft.ReportViewer.WinForms.dll: error CS1684: Warning as Error: Reference to type ‘Microsoft.SqlServer.ReportingServices2005.Execution.Warning’ claims it is defined in ‘c:\Program Files\Microsoft Visual Studio 10.0\ReportViewer\Microsoft.ReportViewer.Common.dll’, but it could not be found
Has anyone seen this before?
In
Microsoft.ReportViewer.WinForms.dllthere is a class definition which usesMicrosoft.ReportingServices.ReportProcessing.RenderingResultas base class;You use this
fooclass somewhere in your code. The classRenderingResultis defined inMicrosoft.ReportViewer.Common.dll. This class requires the same version ofRenderingResultto be referenced. Because you use the 9.0 version of Microsoft.ReportViewer.WinForms.dll and the 10.0 version of Microsoft.ReportViewer.Common.dll they do not match. TheRenderingResultis different in the 10.0 version, so thefooclass definition is incomplete.To resolve this, you need to make sure you use the matching assemblies, for example you might need to manually adjust the
HintPathin the .csproj file to fix this.