I just recently installed Telerik for ASP.NET MVC and in the process upgraded MVC to 5.2.7. I installed MVC using Nuget. Upon running my project, I receive the following error:
Method not found: 'System.Web.Routing.RouteValueDictionary System.Web.WebPages.TypeHelper.ObjectToDictionaryUncached(System.Object)'.
There is another post on this issue, but I have tried the recommendations and haven't found a solution (Mvc 5.1 MissingMethodException System.Web.WebPages.TypeHelper.ObjectToDictionaryUncached).
He mentioned to replace the System.Web.Webpages, which I tried and did not work.
Here is my current Web.config
<dependentAssembly>
<assemblyIdentity name="System.Web.Helpers" publicKeyToken="31bf3856ad364e35" />
<bindingRedirect oldVersion="1.0.0.0-3.0.0.0" newVersion="3.0.0.0" />
</dependentAssembly>
<dependentAssembly>
<assemblyIdentity name="System.Web.WebPages" publicKeyToken="31bf3856ad364e35" />
<bindingRedirect oldVersion="0.0.0.0-3.0.0.0" newVersion="3.0.0.0" />
</dependentAssembly>
<dependentAssembly>
<assemblyIdentity name="System.Web.Mvc" publicKeyToken="31bf3856ad364e35" />
<bindingRedirect oldVersion="0.0.0.0-5.2.7.0" newVersion="5.2.7.0" />
</dependentAssembly>
I need to keep the new version of MVC in order to use Telerik.
What else can I try? I have tried reinstalling MVC, modifing the Web.WebPages dll?
CodePudding user response:
For anyone else struggling with this same issue, I found out that an older version of System.Web.WebPages was still being referenced through the bin folder. Deleting this version and replacing it with the newest dll fixed my issue.