Monday, October 10, 2011

ASP.NET 4.5 & Visual Studio 11. New Features.

Just a few days ago Visual studio 11 developer preview was relased, there is no date announced yet for the final release.


I wrote this post to allow easy finding of what are the new things we will see in .net vnext, or .net 4.5 and Visual Studio 11.


One of the things I liked the most, its minification and bundling, it allows to bundle and minimize .CSS and .JS files so that page load times are greatly reduced.


The entire post can be found here


Other  .net 4.5 resources can be found as well.  As always, read the release notes and play safe, dont use in production environments, yet.



ASP.NET 4.5 Developer Preview

ASP.NET 4.5 is part of the newly announced .NET 4.5 Developer Preview. It's available for MSDN subscribers today (9/14) with general availability on 9/16. This release includes a lot of great core features in the ASP.NET runtime as well as ASP.NET Web Pages enhancements.
Top Links for the ASP.NET 4.5 Developer Preview:
  • http://asp.net/vnext is our hub for new information about what's coming in the next version ASP.NET. Watch it for regular updates... I have production access!
  • Scott Guthrie's vNext blog post series - Scott's begun a series highlighting some of the top features in ASP.NET vNext.
  • ASP.NET vNext video series - these are some great ~1 minute screencasts from the ASP.NET PM's who own the features, and Scott's been featuring them in his aforementioned blog post series. Stand by for a lot more - I've seen the list, and they're really well done.
  • What's New in ASP.NET 4.5 and Visual Web Developer 11 Developer Preview has a ton of information on what's on that way. By "ton" I mean almost 10K words, but broken up by so many beautiful screenshots that it you'll be wishing for more.
Here are some jump links to specific features in ASP.NET 4.5 and ASP.NET from the What's New page to give you an idea of the features:

ASP.NET MVC 4 Developer Preview

The ASP.NET MVC 4 Developer Preview is available now, and you can install it via the Web Platform Installer.
Top Links for the ASP.NET MVC 4 Developer Preview:
  • http://asp.net/mvc/mvc4 - This is our "official" summary page for information ASP.NET MVC 4, and we'll keep this updated with the latest information about ASP.NET MVC 4 through the release cycle.
  • Release Notes - The Release Notes are the best way to find out what's new and changed.
  • ASP.NET MVC Forum - If you run into any questions or issues, posting on the ASP.NET forums is the best way to get feedback from the product team and the broader ASP.NET MVC community.
  • ASP.NET MVC 4 Mobile Features tutorial - ASP.NET MVC 4 has a significant focus on developing for mobile platforms, and Rick Anderson's excellent tutorial is a great way to get up to speed.
  • Phil Haack's blog post (ASP.NET MVC 4 Developer Preview Released) - Phil announces the release as well as his ASP.NET MVC 4 and NuGet related talks at BUILD.
  • ASP.NET MVC 4 Roadmap - The ASP.NET team doesn't keep many secrets, and they publicly announced the complete roadmap for ASP.NET MVC 4 months ago. The Developer Preview hints at where things could go, but if you want to see the complete vision for the released product, the Roadmap is the best way to find out.

Visual Studio 11 Developer Preview

Visual Studio Developer Preview is of course a lot bigger than "just" an update for the web development features, but it's definitely got plenty of them. The new Visual Studio features are also listed in that big What's New page:
Visual Studio 11 is available for MSDN subscribers today (9/14) with general availability on 9/16. You can find more information about Visual Studio 11 Platform Preview on MSDN.

ASP.NET Web Pages 2 Developer Preview

ASP.NET Web Pages 2 has been announced, with more information to follow really soon. Watch the http://asp.net/vnext page for more information. Here's the feature summary:

Saturday, October 8, 2011

Advantages and Disadvantages of ASP.NET Webforms Vs ASP.NET MVC


These are my thoughts according to what I have studied about ASP.NET MVC vs ASP.NET WebForms, its very necessary to know the basic differences between starting the journey of learning MVC and know what the end result will look like in an enterprise application done in MVC.

It might be more time, Completely agree, but at the end you have more control of everything, in the other hand WebForms do most of the hard work for you.

Here are some basic questions I needed to answer my self before starting my first project with MVC, and the community answers I got.


1) MVC has no viewstate? So how can I save data in the current page? This seems a very big disadvantage.
Why do you want to save things in the page? That's what databases are supposed to do. Save data. In the page you simply use a hidden field allowing you to refetch the data from wherever it was initially stored. And for data that can change you have form input fields, so it will be there.

2) Webform says that provide an extensive event model with lots of controls, Doesnt MVC support controls and events as a normal webform?
No, MVC doesn't support controls and events. It supports models, controllers and views.
Lets suppose I am an expert on both? why would I choose one or the other? So far the only good thing about MVC in my opinion is testability, becase Rapid Application Development in webforms win in so many ways to MVC.
That's a subjective question for which there is no objective answer. The answer I can give you is: it will depend on the context. I agree that RAD wins in WebForms, but what you have to remember is that it is not the development of the application that costs most. It's its support and maintenance. So if your application is written rapidly you will ship it quickly indeed but with the time if you don't properly architect it with extensibility in mind this quick application development turns slowly into a nightmare, until the day comes where you simply have to rewrite it because it costs you so much to continue to support it.
Now talking about the RazonEngine, it seems like going back to the old ASP, you cant use server side controls? how is this an advantage for me?
You have total control of the markup, your pages are no longer polluted with useless ViewStates, and at last your markup validates. If you want to reuse some view portions in ASP.NET MVC you could use partial views.
ASP.NET MVC applications hand you back control over the way your application works and it conforms to the 'native' model of HTTP/HTML.
WebForms is an abstraction of web application programming; envisaged to ease the transition for the Visual Basic programmers who were the primary target for .NET when it was launched. The trouble is, it's a 'leaky abstraction'. It uses 'tricks' under the cover to make it appear to operate in a way that is simple for those used to VB's event-based model, such as viewstate and postbacks. The trouble with this (and all those 'leaky abstractions') is that while the basic stuff is easy, once you try to do something that doesn't fit within the abstraction, it gets dramatically more complicated.
If your applications are trivial and the WebForms abstraction consistently works for you, feel free to stick with it. Microsoft have been considerate enough to continue to support it.
But if your applications are at all sophisticated or complex (as more and more are these days), I'd suggest looking at MVC with an open mind.

What is unobstrusive Ajax?

I was looking for this definition and I found the one I like the most:


Unobtrusive Ajax is about making web applications that work for everyone all the time, even if you have JavaScript turned off, or you're using a mobile phone or a screen reader, or however you happen to be using the Web. It's about the separation of behavior (JavaScript), content (HTML), and presentation(CSS).

From: unobtrusive-ajax.pdf

I am not going to paste the entire document or try to write it with my own words, the entire paper has everything explained for anyone to understand it and my idea was to bookmark it for further reading and for my blog visitors to know about this concept, that, by the way is not so new.

In my past projects during the last years I have always developed ASP.NET applications with webforms, instead of MVC, now that I am on my way to studying MVC, I found that in the ASP.NET MVC tutorials they have a tutorial for unobtrusive Ajax, but they didn't explain the concept.

I hope in the next projects to have the opportunity to use this technique, altogether with ASP.NET MVC would make a really nice application that can be used in the most majority of browsers and devices and also would have very good performance  if we use the good ASP.NET MVC practices.



Thursday, July 22, 2010

Free SharePoint Developer Training

Watch and learn from over 12 hours of free, in-depth developer training 
Click the links below to learn from over 12 hours of free, developer training for SharePoint technologies from our principal consultant...
Module 1 - Developing Solutions on the SharePoint Platform

Module 2 - Web Parts

Module 3 - Page Navigation

Module 4 - Page Branding

Module 5 - Data Lists

Module 6 - Web Services

Module 7 - Event Handlers

Module 8 - Content Types and Site Columns

Module 9 - Workflow

Module 10 - User Management

Module 11 - Silverlight

Module 12 - Deployment

SharePoint 2010 Product Documentation

SharePoint Server 2010:
  • SharePoint Server 2010 Tech Center is a gateway into the IT Pro documentation for SharePoint Server 2010 and a location for RSS feeds of new content.  
  • Resource Centers provide information across the product lifecycle for activities and solutions.
  • TechNet articles are organized by the product lifecycle – evaluate, plan, deploy, operate, etc. Content includes a newly published page with an RSS feed, so you can keep up with what we’ve published, and a roadmap to the content.
  • Worksheets are Microsoft Excel files that you can use to record information that you gather and decisions that you make as you plan your deployment of Microsoft SharePoint Server 2010.
  • Models are poster-sized illustrations of Microsoft SharePoint Server 2010 architecture and concepts.
SharePoint Foundation 2010:
  • SharePoint Foundation 2010 Tech Center is a gateway into the IT Pro documentation for SharePoint Foundation 2010 and a location for RSS feeds of new content.
  • Resource Centers provide information across the product lifecycle for activities and solutions.
  • TechNet articles are organized by the product lifecycle – evaluate, plan, deploy, operate, etc. Content includes a newly published page with an RSS feed, so you can keep up with what we’ve published, and a roadmap to the content.
  • Worksheets are Microsoft Excel files that you can use to record information that you gather and decisions that you make as you plan your deployment of Microsoft SharePoint Foundation 2010.
  • Models are poster-sized illustrations of Microsoft SharePoint Foundation 2010 architecture and concepts.
P.S. – Be sure to also check out the following: