Tim Jarvis
Tim Jarvis

Reputation: 18815

CS1702 Runtime error with Kendo.Mvc and System.Web.Mvc 4.0.0.1

We are having an issue trying to get Kendo.Mvc to bind to version 4.0.0.1 of System.Web.Mvc

The Kendo.Mvc version is

Kendo.Mvc, Version=2013.3.1324.440, Culture=neutral, PublicKeyToken=121fae78165ba3d4

This assembly references version 4.0.0.0 of System.Web.Mvc

We've added a binding redirect to our Web.Config

  <dependentAssembly>
    <assemblyIdentity name="System.Web.Mvc" publicKeyToken="31bf3856ad364e35" />
    <bindingRedirect oldVersion="0.0.0.0-4.0.0.0" newVersion="4.0.0.1" />
  </dependentAssembly>

The solution builds just fine, but at run time we get this...

CS1702: Warning as Error: Assuming assembly reference 'System.Web.Mvc, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' matches 'System.Web.Mvc, Version=4.0.0.1, Culture=neutral, PublicKeyToken=31bf3856ad364e35', you may need to supply runtime policy

Upvotes: 3

Views: 1962

Answers (1)

stevieg
stevieg

Reputation: 662

This might help: http://blogs.msdn.com/b/webdev/archive/2014/10/16/10565300.aspx?PageIndex=2. It suggests updating the MVC4 package will help resolve that warning (remove -whatif to actually update)

Update-Package Microsoft.AspNet.Mvc -Version 4.0.40804.0 -whatif

Upvotes: 1

Related Questions