.Net 4.5.1 and MVC 5
I'm trying to integrate RazorGenerator into my solution, but I'm getting an error that RazorGenerator is looking for MVC 3.0.0.1 and isn't finding it. What is the recommended workaround until the update is made?
Can you give more details about the error you're seeing? Is it at design time in VS, or at runtime? What's the full text of the error?
Also, please check what versions of MVC you have in your GAC.
The error is as follows:
Could not load file or assembly 'System.Web.Mvc, Version=3.0.0.1, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies. The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040)
Calling assembly : RazorGenerator.Mvc, Version=2.0.0.0, Culture=neutral, PublicKeyToken=7b26dc2a43f6a0d4.
It's at runtime. The build works just fine. I pulled down the repo and migrated RazorGenerator.Mvc to .Net 4.5.1, and upgraded to MVC 5, which got my solution working. Clunky, but working.
I have no versions of System.Web.Mvc in my GAC
What version of MVC are you intending to use? Do you have the proper bindingRedirect in your web.config?
I'm using MVC5. I have the binding redirect configured as follows:
<dependentAssembly>
<assemblyIdentity name="System.Web.Mvc" publicKeyToken="31bf3856ad364e35" />
<bindingRedirect oldVersion="0.0.0.0-5.2.3.0" newVersion="5.2.3.0" />
</dependentAssembly>
Then normally it should be impossible for 3.0.0.1 to get loaded, so something strange is going on with your app. All MVC assembly loads should end up loading 5.2.3.0.
That was my understanding as well. I'll keep digging. Thanks for your help!
Any update on this?
any update on this? experiencing the same issue.