views:

75

answers:

2

I am using the s#arp framework and want to use the latest mvc contrib. This means that I have to use asp.net mvc 2.0. So I refrenced the latest 2.0 dll for mvc 2.0 and the latest mvc contrib dll but still get this error:

Error 1 Assembly 'MvcContrib, Version=2.0.36.0, Culture=neutral, PublicKeyToken=null' uses 'System.Web.Mvc, Version=2.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' which has a higher version than referenced assembly 'System.Web.Mvc, Version=1.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' c:\Users\bla\Downloads\MVCContrib.release(2)\MvcContrib.dll Bla.Web.Controllers

I checked the mvc dll in my controller project and it is version 2.0. what else can I do?

Thanks!

Chris

A: 

Christian, did you also replace it in your web project? Anywhere 1.0 was referenced, you would need to replace it. In addition, you might need to add an assembly binding redirect from 1.0 to 2.0.

Alec Whittington
Thanks Alec will have a lok at this asap.
csetzkorn
I still get: Error 25 Assembly 'Bla.Web.Controllers, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null' uses 'System.Web.Mvc, Version=2.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' which has a higher version than referenced assembly 'System.Web.Mvc, Version=1.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' I am pretty sure I use the System.Web.Mvc 2.0 dll in both projects and adapted the web.config etc.
csetzkorn
A: 

Chris, I would unload any of the projects that reference System.Web.Mvc and edit them to make sure they are

  • Pointed to the proper version of System.Web.Mvc at the location in the /lib
  • Are not pointed to the global version (gac)
Alec Whittington