Jul 29

I will now describe some new features of Visual Studio 2010. There are many new features so I will not be able to describe each of them. I will begin with the most useful features I discovered.

 

  • Targeting an older version of the .net framework

You are still able to target a specific version of the .NET Framework when you create a new application. Simply choose the needed version in the dropdown list when you create a new application and the list of available project automatically adapts.

image

 

  • Online template

You can now directly search for online template. Simply select the “Online Template” option in the menu.

image

 

  • Dock window wherever you want

A really cool feature allows you to detach a window (for instance the asp.net designer) from the application and dock multiple windows on the same screen or on 2 or more screens. If you add a button on the designer window, the code window will be automatically updated at the same time!

vs2010 - DualScreen 

 

  • Call hierarchy

You can now very easily find out where a method is called and what method does it call with the call hierarchy.

vs2010 - CallHierarchy1 

vs2010 - CallHierarchy

Right click on the method –> Call Hierarchy 

 

  • ASP.NET Surround With

In the ASPx editor, you can now very easily surround a block of code with another.

VS2010 - Surround 

Select code to surround –> Right click –> Surround With

  • ASP.NET Code Snippet

Snippets are available for almost every control. Even shortcut have been added. For instance, you can now add a textbox with the shortcut “tb”.

VS2010 - Snippet1

VS2010 - Snippet2

Press Ctrl+space –> Type tb –> Press tab

  • VB.NET Snippets

A real improvement for VB.NET, code snippets allows you to do almost everything! It’s a pity that this features is not (yet) available in C#.

VS2010 - SnippetVB

Right click –> Insert Snippet

  • Organize Using

A cool feature helps you to clean up the unnecessary “using” statement from a file.

before: VS2010 - OrganizeUsing1  after: VS2010 - OrganizeUsing2

A click on the “Remove and Sort” menu remove the unnecessary using and sort them correctly. Nice!

 

  • Highlight References

If you click on something in the editor, all references of your selection are automatically selected

vs2010 - Highlight

On this picture, I put my mouse on “ls”. All same reference were automatically highlighted.

 

  • Zoon in the editor

You can now zoom in any code editor. Press the CTRL key and press + or scroll with your mouse. Same as in Internet Explorer :-)

vs2010 - Zoom

 

  • Generate class, constructor, method, property or field

A new very cool feature is code generator. You can now generate class, constructor, method, field, properties,… from scratch. Let’s have a look.

In a blank solution we create a new instance of a new class person. This class does not exist yet but just click on it to generate the file and the class. If you choose other, more options are available.

VS2010 - CodeGenerator1

 

Let’s generate the constructor

VS2010 - CodeGenerator2

 

We can also define a new Size property or field and generate it

VS2010 - CodeGenerator3

 

And finally, let’s add a new method GetAge() and generate it

VS2010 - CodeGenerator4

 

And the generated class. Of course, we have to define the code in the GetAge() method but the skeleton is in the class. We can use refactoring methods to rename the generated members and/or arguments if we do not like the generated names.

VS2010 - CodeGenerator5

 

  • Web.config Transformation 

Visual Studio 2010 lets you create configuration file transforms to modify your project's Web.config file to work with various deployment environments. A deployment environment can be a development computer, a testing server, a staging or pre-production server, or a production server. Typically, when you move the application between these environments, various settings in the Web.config file must change. Some of the settings that change between environments include application settings, connection strings, debug flags, and Web service end points. You can get more information on the following blog: http://blogs.msdn.com/webdevtools/archive/2009/05/04/web-deployment-web-config-transformation.aspx

 

  • Breakpoints

    • Trace breakpoint

This feature was already available in previous version of Visual Studio. You can add this kind of breakpoint which allows you to add text to be displayed in the output window. 

    • Breakpoint Labeling

You can now add label to your breakpoints.

 

image

image

What you can do with these groupings is perform various operations on one set of breakpoints without impacting other breakpoints.

    • Import/Export

Using the two new buttons, you can now export or import your breakpoints to a xml files.

image

 

  • Parallel Tasks Window

A new debug window is now available. It allows you to debug code used in parallel code.

 image

image 

 

The list of new features is very big and I am going to learn more about them. Then, in another article, I will post everything I will find interesting and/or useful. Here is a list (not exhaustive) of some of these new features for people who does not want to wait:

  • Reduce block code (if, for, foreach,…)
  • Online template
  • Extensible Test Runner
  • Dynamic Data Tooling
  • WPF-based Editor
  • Click-Once Enhancements for Office
  • Improved WPF Tooling
  • Web Deploy
  • Historical Debugging
  • MVC Tooling
  • Inline Call Tree
  • Minidump Debugging
  • Quick Search
  • Concurrency Profiler
  • JQueryIntellisense
  • Breakpoint Import/Export
  • Document Map Margin
  • 64-bit Mixed-Mode
  • Parallel Stacks Window
  • Improved Multi-Monitor

 

The next part of this series of articles will focus on C# 4.0. Keep in touch :-)

Comments

Torgal

Posted on Tuesday, 4 August 2009 07:46

VS2010 looks great. Looking forward for next post.

tin whiskers

Posted on Thursday, 6 August 2009 05:23

Hi,
  Excellent post..keep up the good work...

verizon dsl reviews

Posted on Friday, 21 August 2009 09:54


I'm not familiar when it comes to this topic but I know it is very important that's why I keep on reading and researching about this to learned something more about this Visual Studio 2010 Beta1. It really helps us a lot. Thank you for sharing some useful information to us!

travel nursing

Posted on Thursday, 8 October 2009 11:49

The new release of Visual Basic 2010 is tightly integrated with the Windows operating system and the .NET programming environment.

Soakaway problems

Posted on Friday, 9 October 2009 10:07

I have been using the express editions of Visual Studio to develop my knowledge for a while and  am starting to undertake the changeover to the pro version. Before I do this I would like to extend my detailed knowledge of using the package before I get out my wallet. My earlier experience is as a web programmer with php, mysql, most linux based tools and a little flash, now I am adopting a Microsoft package. I am finding it is a real learning curve and am attempting to build my knowledge with some specialist blog reading.  The title " A first look at Visual Studio 2010 Beta1  New features " in your post made me fascinated me.  I find the Visual Studio tutorial web sites  are oftentimes strict and mention the identical points looking like an online manual.  Comments and dialog in blogs frequently reference genuine methods to resolve issues which takes me through the learning curve more rapidly.  Thanks for the post.

Yachtcharter Griechenland

Posted on Wednesday, 18 November 2009 07:12

This is such a great resource that you are providing and you give it away for free. I love seeing websites that understand the value of providing a quality resource for free.

pr melbourne

Posted on Monday, 23 November 2009 02:46

What are   new features  of   visual   studio 2010  beta1?

proxy

Posted on Thursday, 17 December 2009 14:43

Great share. Keep up the good work.

ผลบอล

Posted on Monday, 21 December 2009 15:47

This is a very nice post.

unblock myspace

Posted on Tuesday, 22 December 2009 05:47

Great blog, this could be the best blog I ever visited thi month. Never stop to write something useful dude!.

Ggler

Posted on Monday, 28 December 2009 22:24

Nice post. I love it.

sms service

Posted on Monday, 8 February 2010 04:30

Top post. I look forward to reading more. Cheers

Hima

Posted on Monday, 15 February 2010 07:55

Code snippets also available in C# . but not as flexible as VB

Jane @ UK Shopping Online

Posted on Friday, 26 February 2010 07:29

Hey, I'm glad I added you to my RSS, otherwise I'd have missed this post! Thanks for this.

Add comment




  Country flag

biuquote
Loading