Learning Windows Forms

Microsoft Windows Forms is the core development platform for building smart client applications. Some of the world's largest companies, including Bank of New York, Bear Stearns and Company, Bechtel, Credit Suisse First Boston, Dresdner Kleinwort Wasserstein, Hewlett Packard, and Zagat Survey, use Windows Forms for their demanding, mission-critical applications.

Windows Forms 2.0, as part of the Microsoft .NET Framework version 2.0 and Visual Studio 2005, is a major release that includes significant new features elevating the level of functionality for client applications. Visual Studio 2005 is also backwards-compatible with previous versions of Windows Forms, enabling smooth migration and upgrade.

Our work in Visual Studio 2005 has focused around three core goals:

  1. Deployment of client applications. One or our top goals is to bring the ease and reliability of Web application deployment to client applications. We have heard from customers that one of the biggest difficulties with client applications today is deploying the applications to hundreds or thousands of users desktops. In Visual Studio 2005 the ClickOnce technology makes the deployment process as easy as stepping through a wizard within Visual Studio. Additionally, Visual Studio makes the packaging and deploying of the .NET Framework and other pre-requisites the application may require (e.g. MDAC) a simple straight-forward process.

    ClickOnce brings the simplicity of Web deployment to client applications and also provides a significant amount of power and customization to the developer and the administrator. This power and customization ensure that the deployment processes and methodologies within your environment are maintained. For more information about this new feature, see the ClickOnce feature details.

  2. Amazing Visual Presentation. Another key goal, is to enable you, as a developer, to fully brand and customize the visual presentation of your applications. We have heard three pieces of customer feedback over and over again: a) you want to build applications that look like Microsoft Office and like Microsoft Windows, b) you want more flexibility and control over how you can position controls on the forms, and c) you want this functionality included directly in the .NET Framework.

    In Visual Studio 2005, we have added an number of new controls . For example, we have included a new grid control, called the DataGridView, that is extremely fast, powerful, and highly extensible. As a Windows Forms developers, you will also be able to leverage several other new controls, including a MaskedTextBox edit control, a Sound Player control (it does what its name implies), a Web Browser control and an Active Document Host control.

    Moreover, in order to make your application look more like Microsoft Windows or Office, we have made Windows Forms controls render with visual styles by default, and we have created a new menu, toolbar, and status bar family of controls called ToolStrips. ToolStrips are highly customizable and very powerful. If you do not like the default renderers provided in the released version (one of which is Office Professional 2003), you can customize the renderers to your own liking.

  3. Developer Productivity. Yet another major goal in Visual Studio 2005 is to enable you to build client applications faster than ever before both by reducing the number of lines of code you must write and by reducing the number of clicks you must perform at design time to complete common tasks.

    Smart Tags,Document Outline view, and SnapLines are three features designed to reduce the number of clicks for common tasks. When you work with a control, its Smart Tag will be shown. With a Smart Tag, you can quickly perform common tasks and/or directly edit common properties for that specific control. The Document Outline window provides a hierarchical view of all the controls. With this window, you can quickly navigate and control the Z-order of the controls within a container. SnapLines is a new feature that enables you to quickly align controls with each other and the form. The alignment occurs by drawing lines between critical alignment points of the different controls on the form. To help you reduce the amount of code you need to write, Visual Studio 2005 introduces greatly improved support for working with data, as well as two new controls for doing sophisticated custom layouts of controls on forms, a new SplitContainer control that automatically splits the container into two, and new support for user and application settings support for client configuration.

    For more information about these features, see the following articles:

We are enthusiastic about the major improvements that Visual Studio 2005 provides the Windows Forms developer. The combination of Windows Forms in Visual Studio 2005 and the new Visual Studio development tool features complement each other well, enabling you to quickly and easily build applications like never before.