1
Vote

Targeting Framework 4.0 and MVC 3

description

This should fix it if you are having issues:

In web.config,
under system.web/compilation/assemblies, update all the assemblies from Version=3.5.0.0 to Version=4.0.0.0
The <compilation> element should also say targetFramework="4.0"

under runtime/assemblyBinding/dependentAssembly/ look for element <assemblyIdentity> having attribute name="System.Web.Mvc". Change newVersion="2.0.0.0" to newVersion="3.0.0.0" in the corresponding <bindingRedirect> element.

Edit:
Further to this, in order to get model binding to work correctly in User Index and Create views, the web.config in the view folder should also be updated. The assembly refered to by system.web/pages/controls should be updated to version 3.0.0.0.

I have attached a zip containing the two web.config files here.

file attachments

comments