问题
I have installed MVC 4 on visual Studio 2010. Previously MVC 2 and 3 have been installed as well
Everything works fine but when trying to add a controller, I get the following error:
The way I add it :
right click on Model folder > add > controller
When I clean the project and retry it works. But each time I build it then I get the error again untill I clean again.
I can live with that but I realized I cannot add a view(model class) either, the wizard would just close as soon as I check Create a strongly-typed
How can I fix these issue? I know it is related to the Entity framework, but I don't know what to do at this point.
I tried uninstalling then reinstalling using the the console and also NuGet, problem still persist.
回答1:
I gave up on vs 2010 with mvc 4, I use mvc 4 with vs 2012, while you may not have that luxury, you are certainly running into legitimate conflicts with projectguids or assembly references etc...
A few things I suggested in the past may NOT be what you are looking for , I will look further for a solution to your problem, in the interim, see these stackoverflow links
Build Errors - 'System.Web.Mvc.ModelClientValidationRule' Conflicts
ModelClientValidationRule conflict
来源:https://stackoverflow.com/questions/16906303/few-issues-after-installing-mvc-4-on-visual-studio-2010