ASP.NET MVC and Scottish Developers (Demo)

Many thanks to everyone who turned out to the Scottish Developers User Group meeting on Thursday and made it such an enjoyable evening. With such a big turnout it was a little cramped and sometimes difficult to see the screen. other than limiting the numbers (which seems a shame) I'm not sure how we could improve it next time (other than a bigger screen or tiered seating neither of which are very likely given the office is brand new :-)). Shame we couldn't go out on the roof terrace, I hear the views are stunning.

Anyway, aside from my gaff about the ASP.NET MVC Beta being available "in the next few weeks, in fact very soon" (when it had in fact been released that day) and the lack of a microphone, things went reasonably well with lots of questions throughout. I've posted the code for the demo I created (link below) in case you find it useful. Things have changed a bit between Preview 5 and Beta so I updated the demo and added a couple of other things (like adding paging on the Index view and an Ajax helper) that I didn't have time to do on the night. It still looks terrible from a UI perspective but hopefully it gives some insight into the concepts. There are some notes on getting it up and running on the download page.

MVC is a fast moving beast and the "right" way to do things changes from preview to preview with a lot of enhancements to the helpers, embracing the DRY principle and using convention to reduce the amount of code you need to write. Some of the demo may therefore not be optimal - don't treat it as gospel (certainly not the error handling - that's horrible the way I've done it for simplicity. ScottGu's blog post has a much more realistic solution using a RuleViolation class and IRuleEntity interface).

Link to the demo code

Technorati Tags: asp.net,mvc,scottish developers