Top Ten Visual Studio 2005 Enhancements for Windows Forms Development (Part I)

Introduction

We’ve been providing feedback to the Windows Forms and Client Data development teams at Microsoft regarding the next release of the Visual Studio IDE, named Visual Studio 2005, and codenamed “Whidbey”. From our experience with the alpha versions of Visual Studio 2005, the overall theme is definitely improving developer productivity; doing more with fewer mouse-clicks and by writing less code. The following is the first half of a “top-ten” list of features that we have found to be most compelling to our current development projects:

1. Improved Forms Designer

The Forms Designer in Visual Studio 2005 has been improved to allow for more uniform and consistent control placement using Snaplines. Snaplines are visual cues that appear in close proximity to a control when it is dragged onto a form from the toolbox. They provide visual suggestions as to where to place a control relative to other existing controls on the form. Think of this feature as a replacement to “snapto grid”. Instead of a control “snapping” to a specific location on the form, a control now “snaps” to a preferred location relative to other controls on the form.

2. Office 2003 look-and-feel using Toolstrips

Visual Studio 2005 provides Toolstrip controls that consist of menus, toolbars, context menus, and status bars that provide the same look and feel as Office 2003 applications. Now, applications you develop with Visual Studio 2005 will have thesame professional look and feel as Office 2003. With the current development environment, you would need to purchase third-party menu and toolbar controls to get the same look and feel as Office 2003.

3. Native Active Document Control

Active Documents is a COM-based feature of Microsoft Office that allows you to embed an instance of a Word or Excel document as an OLE server. Because this is COM-based technology, accomplishing this in .NET requires that you implement a COM-based OCX control using C++ and ATL and then wrap this control with a .NET Runtime Callable Wrapper (RCW). The native Active Document control provided in Visual Studio 2005 does all this for you in a single native control.

4. Improved Data Binding Features

Visual Studio 2005 now provides a data-centric method of creating a data-bound form instead of the current control-centric approach. In the current version of Visual Studio, you would use the forms designer to layout the controls which you wish to be data bound, then define the data source and data connection for the controls, and then go back to the properties of each control to define the field that is data bound. In Visual Studio 2005, you define the data source and data connection first, and are presented with the collection of data fields that are represented by the data source in a new pane called the DataSet Designer. Using the DataSet Designer, you define the type of control you’d like for each data field. After you’ve done this for all data fields, you simply drag-and-drop the DataSet onto the form, and the forms designer lays out all the data-bound controls on the form for you!

5. New DataNavigator Control

Visual Studio 2005 provides a new DataNavigator control that makes it simple to implement a data-bound form. Think of this control as a “VCR Control” that contains move first, move previous, move next, and move last buttons, as well as a dropdown used to move to a specific record. In addition, add record, update record, and delete record buttons are also provided. This control works in conjunction with a DataConnector and is based on the Toolstrip control mentioned above. While this control provides a standard means of navigation through a DataSet, it is also fully extensible and pluggable.

Summary

Next month, we’ll complete our list of “top-ten” Visual Studio 2005 features for Windows forms development. You can check out the latest Community Technology Preview of Visual Studio 2005 at the MSDN Subscribers download site.