assembly conflict Microsoft.ReportViewer.WebForms

asp.net

Solution

Ran into a similar problem Solution: - Open the References tab on the project that references 'Microsoft.ReportViewer.WebForms' - Select the reference - Microsoft.ReportViewer.WebForms, right click and select the properties option from the context menu. - On the Properties tab ensure that Copy to local is set to True.

Problem

After running a update to published app i get a error : ``` Parser Error Message: Could not load file or assembly 'Microsoft.ReportViewer.WebForms, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies. The system cannot find the file specified. ``` Source Error: ``` Line 1: <%@ Page Title="" Language="C#" MasterPageFile="~/XXX/Pages/MainMaster.Master" AutoEventWireup="true" Line 2: CodeBehind="Report.aspx.cs" Inherits="xxx.yy.cc.tt.Pages.Reports.Report" %><%@ Register Assembly="Microsoft.ReportViewer.WebForms, Version=9.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"Namespace="Microsoft.Reporting.WebForms" TagPrefix="rsweb" %> ``` I haven't updated that to 10.0 -> it should be 9.0 . It is 9 in web.config.. Also it is 9.0 for other apps running in same server. So I wonder, where can it get that request command to search for 10.0 version? As I use Visual Studio 2012 for development, I think it mistakenly did it automatically in some phase. However, as I'm beginner I dont know where to search for that "automatically" modified configuration. Copy-Paste of Web.config: ``` <compilation debug="false" defaultLanguage="c#" targetFramework="4.0"> <assemblies> <add assembly="Microsoft.ReportViewer.WebForms, Version=9.0.0.0, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A"/> <add assembly="Microsoft.ReportViewer.Common, Version=9.0.0.0, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A"/> </assemblies> <buildProviders> <add extension=".rdlc" type="Microsoft.Reporting.RdlBuildProvider, Microsoft.ReportViewer.Common, Version=9.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"/> </buildProviders> </compilation> <httpHandlers> <add path="Reserved.ReportViewerWebControl.axd" verb="*" type="Microsoft.Reporting.WebForms.HttpHandler, Microsoft.ReportViewer.WebForms, Version=9.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" validate="false"/> </httpHandlers> ``` Also its weird if i run the same version i updated it with in my local machine it works.

Original source

Related problems