Converting a ASP.NET MVC 3 Project to MVC 4

后端 未结 4 1316
谎友^
谎友^ 2020-12-08 00:08

What steps should I take to safely upgrade an existing ASP.NET MVC 3 project to the latest ASP.NET MVC 4 Developer Preview?

4条回答
  •  醉梦人生
    2020-12-08 00:41

    Your best bet it's installing the MVC4 from the platform installer. Then follow the steps on the official asp.net/mvc/mvc4 page. If you follow (only) the Shyju instructions It wouldn't work.

    When you end with the official instructions, look on your Views directory, and you may find another web.config with another reference to the MVC assembly and several others for razor. You also want to change the versions of this lines. Basically replace every 3.0.0.0 you find for 4.0.0.0 and 1.0.0.0 for 2.0.0.0

    IF YOU DON'T MAKE THIS LAST CHANGE, YOU MAY END WITH THE ERROR ON THE FOLLOWING QUESTION

    Look for included dll's and make sure they're for the correct versions.

提交回复
热议问题