Previous Section  < Day Day Up >  Next Section

Chapter 6

A1:

System.Windows.Forms.Form is the required base class for a Windows application.

A2:

Docking attaches a control to an edge of its container; anchoring places a control in a fixed position relative to the edge(s) of a container. As the container is resized, the control remains a fixed distance from the edges.

A3:

x and y yield the coordinates. The Button property is set to a MouseButtons enumeration value.

A4:

The Form.TransparencyKey permits part of a form to appear transparent. Any part of the Form have the color assigned to this property becomes transparent. For example, to set the red portion of myForm to red, set the transparencyKey as follows:


myForm.TransparencyKey = Color.Red;


A5:

A modal form maintains focus until it is closed. A modeless form allows the parent form to regain focus.

A6:

The owned form is always on top, and closing or minimizing the parent also closes or minimizes the owned form.

A7:

Minimize and Maximize properties are set to false; the HelpButton property is set to TRue.

A8:

A MouseOver displays information associated with a control's ToolTip. Help text is enabled by pressing F1 or selecting the Help button and clicking a control to show context-sensitive Help.

A9:

Have the original event handler in the base Form call a virtual method to deal with the event. The inheriting Form then overrides the virtual method.

    Previous Section  < Day Day Up >  Next Section