The namespace contains classes for creating Windows-based applications that take full advantage of the rich user interface features available in the Microsoft Windows operating system. The following table shows the classes in namespace grouped into categories. Class category Details Control, User Control, and Form Most classes within the namespace derive from the class. The class provides the base functionality for all controls that are displayed on a . The class represents a window within an application. This includes dialog boxes, modeless windows, and Multiple Document Interface (MDI) client and parent windows. You can also create your own controls by deriving from the class. Menus and Toolbars Windows Forms contains a rich set of classes for creating your own custom toolbars and menus with modern appearance and behavior (look and feel). , , , and can be used to create toolbars, menu bars, context menus, and status bars, respectively. Controls The namespace provides a variety of control classes that you can use to create rich user interfaces. Some controls are designed for data entry within the application, such as and controls. Other controls display application data, such as and . The namespace also provides controls for invoking commands within the application, such as . The control and managed HTML classes, such as , let you display and manipulate HTML pages within your managed Windows Forms application. The control is an advanced data entry control that lets you define masks that automatically accept or reject user input. Additionally, you can use the control to create your own Windows Forms Designer that displays the designer-visible properties of the controls. Layout Several important classes in Windows Forms help control the layout of controls on a display surface, such as a form or control. lays out all the controls it contains in a serial manner, and lets you define cells and rows for laying out controls in a fixed grid. divides your display surface into two or more adjustable parts. Data and Data Binding Windows Forms defines a rich architecture for binding to data sources such as databases and XML files. The control provides a customizable table for displaying data, and lets you customize cells, rows, columns, and borders. The control represents a standardized way to navigate and work with data on a form; is frequently paired with the control to move through data records on a form and interact with them. Components Besides controls, the namespace provides other classes that do not derive from the class but still provide visual features to a Windows-based application. Some classes, such as and , extend the capabilities or provide information to the user. With the and classes, you can display Help information to a user of your applications. Common Dialog Boxes Windows provides several common dialog boxes that you can use to give your application a consistent user interface when performing tasks such as opening and saving files, manipulating the font or text color, or printing. The and classes provide the functionality to display a dialog box that lets the user locate and enter the name of a file to open or save. The class displays a dialog box to change elements of the used by your application. The , , and classes display dialog boxes that enable the user to control aspects of printing documents. For more information about printing from a Windows-based application, see the namespace. Besides the common dialog boxes, the namespace provides the class for displaying a message box that can display and retrieve data from the user. There are several classes within the namespace that provide support to the classes mentioned in the previous summary. Examples of the supporting classes are enumerations, event argument classes, and delegates used by events within controls and components. Classes within the Windows Forms namespace are not supported for use within a Windows service. Trying to use these classes from within a service may produce unexpected problems, such as diminished service performance and run-time exceptions. If you are using .NET Framework version 1.1 or .NET Framework 1.0 and you must make your Windows Forms application support Windows XP visual styles, make sure that you set the FlatStyle property of your controls to and include a manifest with your executable file. A manifest is an XML file that is included either as a resource within your application executable file or as a separate file that resides in the same directory as the executable file. For an example of a manifest, see the Example section for the enumeration. For more information about how to use the visual styles available in Windows XP, see "Using Windows XP Visual Styles in the User Interface Design and Development" in the MSDN Library. By default visual styles are enabled for the .NET Framework versions 1.1, 1.2, and 2.0.