milibay.blogg.se

Appcode folder in asp.net
Appcode folder in asp.net











appcode folder in asp.net

That means for some time there is going to be a mix of web forms and MVC based models-views-controllers in a single web site. I decided to migrate the sample web site in phases. Note, however, that for a new MVC web application (or unless there is some strong reason) it makes sense to follow the default folder structure. So I decided to deviate from the default folder structure.

appcode folder in asp.net appcode folder in asp.net

I was reluctant to change my folder structure just because the default MVC folder structure is something different. For example, all blog post related web forms in one folder, all discussion forum related web forms in another folder etc. This arrangement was on the basis of functionality. The existing web site was having web forms arranged in several folders. Since I already had many classes in App_Code folder, I decided to put my controllers and models in App_Code folder instead of the default Controllers and Models folder. However, if you are developing a brand new web site then more appropriate approach would be to follow the recommended project type (MVC Web Application). That is why I decided to stick with "web site" and not "web application". Since the web site already had a well defined folder structure and classes I decided to follow "minimum changes" approach to this migration. The sample web site I decided to migrate was no exception. Without going into any comparison or debate between project based and project-less development the fact remains that many web sites developed using ASP.NET 2.0 and 3.5 follow project-less structure. At the same time special folders such as App_Code were introduced to keep classes needed by the web site. Based on developer feedback they included it as a part of ASP.NET 2.0. When Microsoft released ASP.NET 1.0 there was no concept of project-less web sites. The Web Forms posted their data to a Controller and controller then took over. At some places I needed to communicate between Web Forms and MVC Controllers.I deviated from the default folder structure for Models, Controllers and Views.I developed the MVC version as a "web site" and not as a "web application".While migrating the web site I did some "non-standard" things including: Though small the web site was having some 20 odd classes in App_Code folder and of course several web forms. Recently I migrated one of my ASP.NET 2.0 web sites to MVC 2.0. In this article I am going to explain how I solved this issue in one of my application. There is no option to create MVC Web Sites. If you used ASP.NET MVC before, you are probably aware that Visual Studio provides ASP.NET MVC Web Application project template to create MVC based applications.













Appcode folder in asp.net