![]() ![]() | ||
We've discussed checkboxes in the In Depth section of this chapter; they're based on the CheckBox class, which has this class hierarchy:
Object MarshalByRefObject Component Control ButtonBase CheckBox
You can find the more notable public properties of the CheckBox class in Table 6.3 and the more notable events in Table 6.4, including those inherited from the ButtonBase class. Note that as with other controls, I am not listing the notable properties, methods, and events CheckBox inherits from the Control class, such as the Click event—you can see all that in Tables 5.1, 5.2, and 5.3 in Chapter 5.
Property |
Means |
---|---|
Appearance |
Gets/sets the appearance of a checkbox. |
AutoCheck |
Specifies if the Checked or CheckState values and the checkbox's appearance are automatically changed when the checkbox is clicked. |
CheckAlign |
Gets/sets the horizontal and vertical alignment of a checkbox in a checkbox control. |
Checked |
Gets/sets a value indicating if the checkbox is in the checked state. |
CheckState |
Gets/sets the state of a three-state checkbox. |
FlatStyle |
Gets/sets the flat style appearance of the checkbox. |
Image |
Gets/sets the image that is displayed in a checkbox. |
ImageAlign |
Gets/sets the alignment of the image on the checkbox. |
ImageIndex |
Gets/sets the image list index value of the image displayed in the checkbox. |
ImageList |
Gets/sets the ImageList that contains the image displayed in a checkbox. |
ThreeState |
Specifies if the checkbox will allow three check states rather than two. |
Event |
Means |
---|---|
AppearanceChanged |
Occurs when the Appearance property changes. |
CheckedChanged |
Occurs when the Checked property changes. |
CheckStateChanged |
Occurs when the CheckState property changes. |
![]() ![]() | ||