If only I were

Building Great Software

Posts Tagged ‘ASP.Net MVC

jQuery and ASP.NET MVC

with one comment

I just saw Scott Hanselman’s announcement that jQuery is going to be packaged with ASP.NET MVC. If you haven’t already been using this Javascript library with ASP.NET development you are missing out on a great library.

For more about this announcement see Scott Guthrie’s post and John Resig’s post.

This doesn’t change anything for me as I’ve been using jQuery in my ASP.NET and ASP.NET MVC projects for about 8 months, but having it packaged in will bring much wider adoption to this library. I think there will be a lot of happier web developers because of this choice.

Written by Chris Sutton

September 28, 2008 at 12:50 pm

Posted in Technology

Tagged with ,

Who and What is ASP.NET MVC for?

with 3 comments

Michael Neel wrote today about what a good definition is for ASP.NET MVC.

I have to admit that many of my descriptions of ASP.NET MVC have been tied to deficiencies and frustrations in the current ASP.NET Webforms implementation. It is time to start talking less about what it isn’t and to start talking more about what it is.

Michael also points out that it is not likely people will use ASP.NET MVC just so they can use the MVC pattern, since you could come pretty close to MVC with some extra work in ASP.NET Webforms.

The main point of the post was to figure out a good definition of ASP.NET MVC that doesn’t rely on problems in Webforms. And here is where I don’t think he captured what ASP.NET MVC is about. Michael ends up with this definition

“ASP.NET MVC is the evolution of Classic ASP, adding an easier separation of concerns while not using an event based model like WebForms.”

First off, I used Classic ASP successfully for several years, but I don’t think there is enough in common to invoke Classic ASP in this definition. What we typed in .asp pages looked like what you make with .aspx pages in the default view engine, but beyond that I can’t find much similarity.

Second, he ends up counter balancing ASP.NET MVC against the event model. I’m thrilled that most of the event model has gone away with MVC, but isn’t this part of the definition implying that there is a problem with the event model in ASP.NET Webforms? So I think to define what value a company would get from ASP.NET MVC you need to counter balance it against the current Webforms implementation (to a degree). But it definitely needs stand more on it’s own as it grows up.

Anyway, Michael’s post has has really got me thinking. In an interview this week I was explaining to an architect why one would want to use ASP.NET MVC and I think I was able to articulate pretty well why you would want to use it and who would not benefit so much from it. I don’t have a better succinct definition yet.

So what benefits does ASP.NET MVC have for me?

It encourages me to separate out fundamental concerns. I want my tools to encourage me along a successful path. They can’t make me build good applications, but they can give me a good model. Having a View that is just about transforming data into a page (or some other format) is good. There isn’t much temptation to put business, data or flow logic in the view. The Controller accepts requests in a predictable format, finds out what Model it needs to call and says what view to render if necessary. The Model can easily be decoupled from the first two parts.

Routing is a first class concept now giving me a prescriptive way to specify a request format. It’s not an after thought like url rewriting.

ASP.NET MVC certainly flattens out the complex Webforms event model. Any time I can cut unneeded complexity from an application I will. I can’t imagine Webforms without preinit, init, render, etc.

As I do more and more TDD with web development, I know that ASP.NET MVC is easier to unit test.

Last of all, it takes me closer to the HTML, CSS and JavaScript. Some people want to pretend these languages don’t exist and want to do Winforms on the Web and others just don’t want to have to deal with the quirks of those languages. I make no claim that they are perfect, but they are good enough and by this point in web history there is agreement on their implementations.

Can we quite having to write ASP.NET MVC? It would be good to have a shorter name for writing. And yes, I ended my title in a preposition, get over it.

Written by Chris Sutton

July 26, 2008 at 3:42 pm

Twin Cities Code Camp MVC Session

with one comment

Thanks to everyone who attended my ASP.Net MVC session. I hope you enjoyed it and I hope you get the opportunity to try out what the MVC framework has to offer. The slides have a lot more information than what I was able to get through in my talk. The project is still very young, but has so much potential.

Please leave comments here and let me know what you thought of the session. I’m trying to constantly improve it to make it the right fit.

More ASP.Net MVC Slides.

Written by Chris Sutton

April 8, 2008 at 11:41 am

Twin Cities Code Camp IV

with 3 comments

Yesterday, I was in the Cities at the fourth Twin Cities Code Camp.  It really was a fantastic experience, likely the the best one yet (I presented at the first two code camps as well). From the presentations I attended I would say that the quality of the presentations was very high. They easily would rival what you get at a paid conference. I also met a bunch of people I had never seen in person which is really cool.

Some of the Iowa crowd that went up was Javier Lozano, Bryan Sampica and Greg Wilson. There were several other attendees from Bryan’s company as well. The Iowa presenters and attendees have grown significantly since the first one where I was the sole Iowan as far as I know.

Some interesting people I met/saw were D’Arcy Lussier, Neil Iverson (Inetium), Brandy Favilla (New Horizons), Robert Boedigheimer, Chris Williams (Magenic), Aaron Erickson (Magenic), Kent Tegels (DevelopMentor), Jeff Ferguson, Chris Johnson, Saviz Artang, John Thurow, Kirstin (Magenic), Nicole and Kristen (New Horizons) and Justin Chase.

My favorite session was Neil Iverson’s PowerShell for Developers.  It was a fast paced live demo that kept incrementally building.  Rarely have I been so engaged in a session. D’Arcy’s MVC vs ASP.Net talk was also really interesting.  We only had about 6 people in the session, so we went around the room and said where we were coming from in our ASP.Net development experience. Then D’Arcy showed us how he typically structures his webforms applications, and we peppered him with questions.  I learned a lot from the session.

My talk was the second of the day in the large seminar room so we actually had about 50 people in the session.  One thing that was cool was that D’Arcy Lussier did an intro talk right before mine, so I got to build off of what he did in the session before. Mine seemed to go pretty well. There were a lot of questions and interest in what MVC brings to web development in the Microsoft space.

Jason Bock did a great job again bringing this all together.  It’s a lot of work coordinating an event like this.

If you liked what you got at the Twin Cities Code Camp you’ll definitely want to check out the Iowa Code Camp.  We’ll be a little bit smaller, but have some top notch presenters, a great facility and will have great prizes as well.  The registration is right on the home page and is as simple as it gets.

Written by Chris Sutton

April 6, 2008 at 9:27 pm

Cedar Rapids 2008 Launch Event

leave a comment »

This Monday, March 17th, is our CRIneta.org Visual Studio/SQL Server 2008 Launch Event.  If you want to learn about the new products and you want to have a great time and win from a huge pool of excellent prizes, then go to CRIneta.org and RSVP to be a part of this event.

Tim Barcz, Greg Sohl, Arian Kulp and I are presenting sessions on Visual Studio enhancements, Linq, IIS 7, C# 3, the new .Net Framework features and the new SQL data types.

We have room for 50 people and 38 are RSVP’d already, so don’t wait too long. We are doing the Launch at the Marriott on Collins road in Cedar Rapids. Check the website for more details.

Written by Chris Sutton

March 13, 2008 at 9:18 pm

Iowa Code Camp – Spring 2008

leave a comment »

We are planning our first ever Iowa Code Camp.  It’s going to happen at the University of Iowa’s Conference Center in Iowa City on Saturday May 3rd.

The details are coming together nicely and we already have about 1/2 of our speakers in place.

Our current sponsors are:

  • University of Iowa
  • Microsoft
  • And several others are in the works

We are currently looking for more sponsors to provide some good food, drinks and prizes.

If you are interested in helping in any way, leave me a comment and I’ll make sure to pass your information on to the right person.

Javier has already posted the Code Camp on bostondotnet.org

ASP.Net MVC Quickstart

with 3 comments

The MVC Toolkit has finally been released as a CTP. Go here to start out – this is the official page with all the links and info you need. Here is the official quickstart link.

kick it on DotNetKicks.com

Update: 1/17/2008

Jeffery Palermo has a great list of his links to get you started.

Links for ASP.Net MVC Reading:

Scott Guthrie is the grandmaster of this project and has posted extensively on different aspects of the MVC framework. Here are some quick links to get you going.

Original post about ASP.Net MVC: http://weblogs.asp.net/scottgu/archive/2007/10/14/asp-net-mvc-framework.aspx

MVC Part 1: http://weblogs.asp.net/scottgu/archive/2007/11/13/asp-net-mvc-framework-part-1.aspx

MVC Part 2(URL Routing): http://weblogs.asp.net/scottgu/archive/2007/12/03/asp-net-mvc-framework-part-2-url-routing.aspx

MVC Part 3(Passing ViewData): http://weblogs.asp.net/scottgu/archive/2007/12/06/asp-net-mvc-framework-part-3-passing-viewdata-from-controllers-to-views.aspx

MVC Part 4(Form editing and posting): http://weblogs.asp.net/scottgu/archive/2007/12/09/asp-net-mvc-framework-part-4-handling-form-edit-and-post-scenarios.aspx

Jeffery Palermo of CodeBetter and Party with Palermo Fame has written some about the MVC bits as well. He has an mvccontrib project.  Read about the guidelines for participation.

Rob Conery talks about how to use use a RESTful architecture with ASP.Net MVC.

Nikhil Kothari has a great post showing how to build a basic app.

Links for Listening:

Polymorphic Podcast with Jeffery Palermo: http://polymorphicpodcast.com/shows/aspnetmvc/

If you want the best information on the ASP.Net MVC there are a couple of other people you should be paying attention to: Phil Haack and Fredrik Normén.

I will be updating this post with more information as I find it out.

Well I have some digging to do. I need to get the bits installed for some client work that will be using MVC early next year.

 

kick it on DotNetKicks.com

Written by Chris Sutton

December 9, 2007 at 9:39 pm

Posted in Uncategorized

Tagged with , , , , , , ,

SubSonic, MVC and IronRuby

leave a comment »

Well Microsoft has been snatching up people from the .Net/ASP.Net community.  First Scott Hanselman, next Phil Haack and now Rob Conery.

I think Scott Guthrie has made some great decisions here.  Scott Hanselman’s blog is one of the most widely read in the .Net community. It’s certainly one of the most popular and he is a interesting and well thought out sort of guy. Scott did one of the first demos of the MVC framework at ALT.Net in Austin.

Phil Haack is now working on the MVC framework.  He has great ASP.Net experience and has a good following of readers as well.

I think Mr. Guthrie’s most interesting and exciting acquisition is Rob Conery of SubSonic fame.  I’ve had client projects in production with SubSonic since its 1.0.4 release and have enjoyed what it brings to the table. At 1.0.4 there were definitely some pieces that needed to be ironed out, but it is very stable at this point, version 2.0.3.

There are really two tools/tool suites that save me vast amounts of time in my web development.  SubSonic is definitely one of them. The other is not relevant here but happens to be Red Gate’s SQL tools.

So Rob is going to keep doing his open source work on that project which ironically is hosted on Google’s project site.  But I’m sure they are going to make it work well with the MVC framework.

I wonder how long Eric Kemp is safe considering he is Rob’s right hand man and has been doing much of the work on the SubSonic project?

The last piece, but certainly just as interesting and important here, is Microsoft’s hiring of John Lam to work on IronRuby.

So imagine what you’ll soon be able to do in VS 2008.  Set up a new MVC web project.  Use SubSonic(or another project) for your models, Phil, Scott Guthrie and others are building the support for views and controllers. Now you need the glue to pull this all together.  John Lam’s IronRuby will fit in here nicely and now the need for Ruby on Rails in the .Net world is greatly diminished.  Of course C# will work just fine as well.

I like what Ruby on Rails has done (I was just out at RailsConf in May), but if this MVC framework ends up being built well, we’ll have every thing we need without going outside of VS 2008.

I’m excited about the possibilities here.

kick it on DotNetKicks.com

Written by Chris Sutton

November 2, 2007 at 9:28 am

ASP.Net MVC and the developer divide

leave a comment »

Mads Kristensen says that the MVC is cool, but that it will divide the community.  Novice and hobby developers will go with the current ASP.Net system and more experienced developers will go to the MVC.

I think he is right.  It will cause a divide, but the benefits of having a real MVC framework will far outweigh the division of developers into these two camps.  The experienced developers will know both well and the beginners will have to realize that they have more to learn.

Many very experienced developers will likely not just move over to the MVC framework any way. They may have 5-6 years of work invested in their current system and it won’t necessarily be beneficial to rewrite them. 

I also think that since so many experienced developer have such deep knowledge bases in the current postback model they likely won’t start new work in the MVC framework.  It’ll just be too much new learning that they can already do effectively in they current way of doing things.

As for me, I have a government client that is moving from Cold Fusion and wants to jump right up to the MVC framework.  I’m excited about this and think they are making a good choice.

Written by Chris Sutton

November 2, 2007 at 8:21 am

Posted in Technology

Tagged with , , ,

Follow

Get every new post delivered to your Inbox.