I’d like to add MVC support to an existing Website project (not a Web application project) and have a few questions.
- To get Visual Studio’s MVC goodness, it appears that I need to update the
.csprojfile’s<ProjectTypeGuids>node. There is nocsprojfile in a website project. - It appears that I need to create
ModelsandControllersfolder in theApp_Code. Is this true? I prefer having these folders under root. - For
Viewsshould I be creating aaspxandaspx.csfiles? Iscshtmlrazor files supported in this kind of a setup?
Any other responses are appreciated. Thanks
I’ve successfully added a ASP.NET MVC 3 to Webforms project and here are some suggestions:
Controllersas a separate class library project and add a reference to this project from the Web forms web project{E53F8FEA-EAE0-44A6-8774-FFD645390401}to the.csprojfile didn’t help.Viewsfolder to the rootModelswithinApp_CodeSystem.Web.RazorandSystem.Web.WebPagesreferencesWeb.configper this post