2013-07-08

A quick guide to choosing the right ASP.NET programming modal for your project

First of all, I must say that choosing the right programming modal for your ASP.NET project really depends on lot of factors like project requirements, the knowledge of the team, the time duration set for the project etc. What I’m trying to discuss in this article is providing a brief overview of how to decide what programming modal should be use for your project.
If you choose the right programming modal according to the project, every programming modal can be used very powerfully and effectively. Basically there are 3 programming modals in ASP.NET
  1. WebForms
  2. MVC
  3. WebPages
I would not discuss about pros and cons in each modal or compare/contrast those. I will take some situations and point out what modal would be the ideal choice.
  • You need friendly URLs for SEO – Since the MVC have a default URL routing logic, MVC will make it easier. If you use WebForms, you would have to write the routing logic.
  • Performance – Performance wise, MVC is better than WebForms. That’s mainly because MVC does not make use of ViewState which carry a lot of information to the server.
  • Experience of the developers – If the developers are much more familiar with WinForms development, they will find it easier to develop with WebForms. WebForms is an event driven development modal. And also, we can drag and drop controls to our page just like we did in WinForm applications. So developers will find a lot of similarities between developing WinForms and WebForms. MVC, on the other hand, requires a good basic understanding of how the web applications work. If the developers are really novice and newbies to web developments, WebPages would be a better choice. It’s light weighted and easier to understand compared to other two.
  • You need a good control of the UI – There is a much more control over the UI if you use MVC over WebForms. MVC will allow developers to create the UI independently from the server code.
  • You need a good separation of the UI and server side code – Since MVC works as Modal-View-Controller, it allows developers to work independently of the server side code and UI. This comes very useful if the UI is going to be designed by a web designer and server side code is going to develop by a web developer. If you use WebForms, it’s not possible (Or at least, really hard) to work on a one page by many people because it tightly couples with the code behind file.
  • Rapid Application Development – If the project is about developing it as soon as you can and if you don’t have to care much about performance, then WebForms would be a better approach. This is true mostly for the intranet web applications. In an intranet application, you don’t have to worry about Search Engine Optimization too. So WebForms will be an ideal choice to develop intranet web applications because you don’t have to worry much about the performance and SEO aspects.
  • You need a test driven environment – Unit testing is much more easier in MVC framework than in WebForms.
MVC seems to over complicate simple things. But once you have a good grasp of it, things will turn out really easy for you. Above are few of the factors which affect for deciding the program modal. There are many more.

No comments: