Getting Started with ASP.NET MVC 3 and Razor

I had a chance to give a talk on ASP.NET MVC 3, Razor and jQuery today at a company and wanted to post the slides and demos from the talk. The focus was on getting started with ASP.NET MVC 3 projects and .cshtml files including creating pages using the new Razor syntax (which I personally love….never going back to the Web Forms View Engine) as well as working with jQuery. Topics covered in the demos (download below) include:

  • Binding form data to custom object properties
  • Validating a model using data annotations and IValidatableObject
  • Integrating jQuery into MVC sites (using the DataTables plugin)
  • Using the new WebGrid class to generate tables with sorting and paging functionality
  • Integrating Silverlight applications into MVC sites
  • Exposing JSON data from a controller action and consuming it in Silverlight
  • Using the Ajax helper to add AJAX functionality (without jQuery)

 

 

The code and slides from the talk can be downloaded here.

 

 

Logo_702D5F60[1]

If you or your company is interested in training, consulting or mentoring on jQuery or .NET technologies please visit http://www.thewahlingroup.com for more information. We’ve provided training, consulting and mentoring services to some of the largest companies in the world and would enjoy sharing our knowledge and real-world lessons learned with you.

Published Tuesday, February 22, 2011 5:07 PM by dwahlin

Comments

# Twitter Trackbacks for Getting Started with ASP.NET MVC 3 and Razor - Dan Wahlin's WebLog [asp.net] on Topsy.com

Pingback from  Twitter Trackbacks for                 Getting Started with ASP.NET MVC 3 and Razor - Dan Wahlin's WebLog         [asp.net]        on Topsy.com

# Getting Started with ASP.NET MVC 3 and Razor – Dan Wahlin's WebLog - asp

Pingback from  Getting Started with ASP.NET MVC 3 and Razor – Dan Wahlin's WebLog - asp

# Dew Drop – February 23, 2011 | Alvin Ashcraft's Morning Dew

Wednesday, February 23, 2011 9:58 AM by Dew Drop – February 23, 2011 | Alvin Ashcraft's Morning Dew

Pingback from  Dew Drop – February 23, 2011 | Alvin Ashcraft's Morning Dew

# re: Getting Started with ASP.NET MVC 3 and Razor

Thursday, February 24, 2011 4:22 AM by Brij Mohan

Thanks for the codes and slides. In fact I am just a begineer with Razor, but I am working with Silverlgiht. Just wanted to check do we have any realtime use of Silverlight with Razor or MVC ?

Because MVC is meant for clear seperation of Model View and Controller, but in a way Silverlight sits in View and Violating the key principals of MVC. Please suggest. Thanks.

# re: Getting Started with ASP.NET MVC 3 and Razor

Thursday, February 24, 2011 10:57 AM by dwahlin

Hi Brij,

You can get the same benefits of MVC in Silverlight with the MVVM pattern.  It's really nice to work with if you haven't seen it already (weblogs.asp.net/.../getting-started-with-the-mvvm-pattern-in-silverlight-applications.aspx). As far as your question about "do we have any realtime use of Silverlight with Razor or MVC?" I'm not sure what you mean there exactly. If you can give me more detail on what you mean I'll be happy to respond.

Dan

# Getting Started with ASP.NET MVC

Wednesday, March 02, 2011 4:12 AM by Getting Started with ASP.NET MVC

Pingback from  Getting Started with ASP.NET MVC

# re: Getting Started with ASP.NET MVC 3 and Razor

Wednesday, March 02, 2011 11:42 PM by akachai kaning

Thanks for this post, it helps me to jump start with ASP.NET MVC.

# Developing a Simple Contacts Manager with ASP .NET MVC 3 and Razor « Arjun's Blog

Pingback from  Developing a Simple Contacts Manager with ASP .NET MVC 3 and Razor «  Arjun's Blog