Getting "System.Web.Mvc.ViewMasterPage" is a mixed error message

Iam is working on the mvc 2 Rc project. It worked fine until this morning. In the morning I received an error message.

Parser error message: the type "System.Web.Mvc.ViewMasterPage" is ambiguous: it can be obtained from the assembly "C: \ Intersight \ IntersightWeb \ bin \ IntersightWeb.DLL" or the assembly assembly C: \ WINDOWS \\ GAC_MSIL \ System. Web.Mvc \ 2.0.0.0__31bf3856ad364e35 \ System.Web.Mvc.dll. Please specify the assembly explicitly in the type name.

enter image description here

But in the previous version, this was normal. I tried to fix the above issues in many ways. Please help me continue.

+8
asp.net-mvc-2
source share
1 answer

There are many reasons for this error.

My typical solution for this: Open your links, go to the System.Web.Mvc properties and check Copy Local - this is true. If so, try setting this to False and remove the DLL from the bin folder, then Ctrl-F5 again.

Other fixes:

  • You can set the referenced assemblies not to be copied to the bin folder (right-click the link and select properties)
  • Maybe your links point to the old dll. You can fix this with an open project using Visual Studio, and in Solution Explorer, expand the Links node. Remove the link to System.Web.Mvc (which points to build version 1.0). Add a link to System.Web.Mvc (V2.0.0.0).
  • Uninstall mvc and reinstall it. Download MVC2 RC
+3
source share

All Articles