Home > .NET 3.5, ASP.NET, Web Development > ASP.NET MVC

ASP.NET MVC

March 5, 2008

As I posted previously, I’ve been struggling with ASP.NET.? Over the last couple of weeks, I’ve come to acknowledge that at the heart of my struggles is a failure to grasp the logic behind the ASP.NET approach. Of course, begin constantly bitten by newbie bugs is very disheartening for someone with almost ten years of web development, but I have tried to put my pride aside and just come to grips with it. This has been increasingly difficult to do as my frustrations mount, although finding the Wizard control alleviated some of it.

I have been in the process of learning about Data Caching in ASP.NET, which I think will address one of my (many) concerns, but such study requires frequent breaks, during which I usually read some other technical information. It was during one of these breaks yesterday that I picked up the Jan/Feb issue of CoDe: Component Developr Magazine, and doing so may have saved my relationship with ASP.NET.? In it, I came across an article by Jeffrey Palermo entitled “Use the ASP.NET MVC Framework to Write Web Apps without Viewstate or Postbacks” – Note to Jeffrey: bloggers like short titles!? The two page article made me sit up and take notice, and I spent the rest of the day researching ASP.NET MVC.? Championed by none other than Scott Guthrie (ScottGu to his readers), ASP.NET MVC is part of the ASP.NET 3.5 Extensions project hosted at asp.net.? This project was recently released as a CTP and is now available for download.? You can get lots more information about it at Scott’s blog.

By freeing ourselves from the mantra of the PostBack, this MVC approach returns us to real HTML control, without the need to wrap all the content in a runat=server form.? This means you can finally put regular HTML forms on your pages. And best of all, you can still use all the ASP.NET goodies, just in a better architecture: Master Pages, ASP Controls, Code Behind, the works.

Downloading and installing the Extensions CTPwas a snap.? Naturally, it integrates with VS2008, so once it is installed you will see some new project types, a couple of which are MVC specific. Selecting one of these project types will create a project with all the plumbing in place and wired, which I immediately found intuitive and well designed. There are several extra, but well documented, steps you must go through if you wish to add MVC to an existing project, but since I don’t really have any of consequence this was not an issue for me.

Hopefully, this afternoon I will find more time to delve into this further.? I can say that I am very excited by this development.? I can finally do things with ASP.NET that are familiar and comfortable.? Projects like this could easily increase ASP.NET adoption and proliferation. My enthusiastic thanks go to all those involved!

Advertisement
%d bloggers like this: