Welcome Guest!
Create Account | Login
Locator+ Code:

Search:
FTPOnline Channels Conferences Resources Hot Topics Partner Sites Magazines About FTP RSS 2.0 Feed

Back to VSLive! San Francisco Show Daily Home

email article
printer friendly

Top 10 Visual C# 2005 IDE Enhancements
Refactoring and object data binding are among the improved features in Visual C# 2005.
by Daniel Fernandez

VSLive! San Francisco, February 10, 2005

VSLive! attendees got a preview of Visual Studio 2005 at .NET Focus Day this week. Here are 10 improvements you can look forward to in the Visual C# 2005 IDE. (Also see the sidebar, "Top 10 Visual Basic 2005 Perks.")

9. Auto using Statements
How many times have you been typing code in Visual Studio and you suddenly notice that IntelliSense stops working? One of the most common reasons for this is that your code is missing a using statement to fully qualify the data type. Visual Studio 2005 can now intelligently detect whether your code is missing a using statement through a Smart Tag. You will have the option of adding a using statement or providing the fully qualified name of the type by including the namespace.

ADVERTISEMENT

8. Configurable Code Formatting and Coloring
C# developers spend a lot of time beautifying their code. Visual C# 2005 provides customizable configuration settings that enable you to control every aspect of your code, including formatting options for new lines, spacing, and wrapping. You'll also be able to customize coloring of .NET types such as value types, delegates, enums, and interfaces (see Figure 1).

7. Code Definition Window
The Code Definition Window dynamically displays the definition of any type that you place your cursor on (see Figure 2). This handy feature simplifies the process of seeing two sets of code at the same time.

6. Object Data Binding
Middle-tier component developers can now easily bind their business objects, including generic collections, to Windows Forms or ASP.NET Web controls.

5. Debugger Visualizers
Visualizers enable developers to visualize complex data types such as XML data or a DataSet while in debug mode. Visualizers are extensible, so developers and component providers can create custom visualizations for their own types.

4. Class Designer
Class Designer is a new feature that provides a visual representation of your source code and .NET types (see Figure 3). As with other visual designers in Visual Studio 2005, changes made visually are reflected in the code, and vice versa.

3. Enhanced IntelliSense
IntelliSense has been enhanced in two important ways. First, IntelliSense fully understands .NET generic types and intelligently provides completion lists depending on the generic type signature. Second, IntelliSense now provides more context-sensitive filtered completion lists. For example, when you're typing a try/catch clause, IntelliSense will automatically filter all types so that only exception types are visible in the completion list (see Figure 4).

2. IntelliSense Code Snippets
IntelliSense Code Snippets are extensible fill-in-the-blank snippets of code. They simplify the amount of manual code you need to write by providing templates for common snippets such as a property addition, a for loop, an indexer, and more.

1. Edit and Continue
Love it or hate it, Edit and Continue is now available for Visual C# 2005 developers. Edit and Continue enables you to change your source code while an application is being debugged, and apply the code changes without having to stop execution, rebuild, and run the application again.

0. Refactoring
The #0 (we are C# developers, after all) IDE enhancement for C# developers is refactoring. Refactoring enables developers to automate many of the common tasks when restructuring code. For example, if you need to rename a textbox control from "textBox1" to something more meaningful such as "txtFirstName," you can use the rename refactoring to find all the correctly scoped references to textBox1 and automatically update your code (see Figure 5). The Visual C# 2005 IDE will include several types of refactorings, including:

  • Extract Method
  • Encapsulate Field
  • Extract Interface
  • Reorder Parameters
  • Remove Parameters
  • Rename
  • Promote Local Variable to Parameter

About the Author
Daniel Fernandez is the C# Product Manager in the Developer Division at Microsoft. He has been with Microsoft since 2001, most recently working as a Developer Evangelist in the mid-Atlantic district. Reach him at danielfe@microsoft.com.



Back to top










Java Pro | Visual Studio Magazine | Windows Server System Magazine
.NET Magazine | Enterprise Architect | XML & Web Services Magazine
VSLive! | Thunder Lizard Events | Discussions | Newsletters | FTPOnline Home