In this article, you will learn the basics of the Windows Forms platform and how to write Windows applications using Windows forms and controls. The space allocated to this article prevents an exploration of every control in the System.Windows.Forms namespace, but the following key topics are discussed and should provide the reader an ample grounding with which to tackle any orphaned controls:
- Windows Forms and the advantages of using forms
- Developing Windows applications using Windows Forms
- The basics of the System.Windows.Forms namespace and its classes such as Form, Control, and other control classes
- Working with menus, toolbars, ToolTips, and status bars
- Working with dialog boxes
- Working with common dialog classes
Windows Forms
Windows Forms is a framework located in the System.Windows.Forms.dll assembly for building Windows applications in .NET based on a graphical user interface (GUI). Any language that supports the common language runtime (CLR) can use Windows Forms.
Why Windows Forms?
If you have programmed in Visual Basic (VB), you are probably familiar with forms. In VB, all windows are forms. Controls are placed on forms to develop GUI applications. Visual C++ developers will more likely be familiar with windows and dialogs rather than forms (CWnd and CDialog in Microsoft Foundation Classes [MFC]).
The Microsoft .NET Framework is designed to remedy this "forms versus windows" situation. All windows are forms, including dialog boxes. From all of this synergy, Microsoft coined the term Windows form. Now developers using any .NET-supported language have access to the same windowing classes, whether they work with C#, VB, C++, or any other .NET-compliant language. This language independence has been extended to support many more languages, including COBOL.
In addition to the preceding, the main benefits of Windows Forms are its ease of use, the standardization of the control hierarchy, and that it allows for rapid application development (RAD). Changing the colors and fonts of controls using MFC or Win32 can be a real headache. The .NET Framework has taken care of most such problems and inconveniences.
In addition, Windows Forms applications provide the following:
- Simple and flexible property support, modeled after
- Common control support, including support for font and color dialogs
- Support for Web Services
- Data-aware controls using ADO.NET
- ActiveX support
- GDI+ (Graphical Device Interface +), a better and richer graphics library, which supports alpha blending, texture brushes, advanced transformations, and rich text
- Metadata support




Sam HobbsPosted Nov 23, 2014, 12:06 AM
Note that for C++ MFC does have the CFormView class. I assume (I do not know) that the CFormView class contributed to the design of Windows Forms. In MFC it was easy to derive a control from a MFC control. It is difficult to do the equivalent in Windows Forms, not with the flexibility that MFC does.