CheckBox

CheckBoxes are square boxes used to set independent options. When they are selected, they contain a check mark; when they are not selected, they are empty.

The sample is a rectangle with the label Show in its top left corner. It contains four vertically aligned boxes respectively labeled Name, Department, Job Title, and Salary. The first three check boxes contain checkmarks to show they are selected. The last check box is blank.

CheckBoxes are independent of each other. You can group them in a GroupBox or rectangle to make the window easier to understand and use, but that does not affect the CheckBoxes' behavior; they are still independent.

Using three states

CheckBoxes usually have two states: on and off. But sometimes you need to represent a third state, such as Unknown. The third state displays as a grayed box with a check mark.

The sample is a rectangle that contains three vertically aligned boxes labeled On, Off, and Third State. The first two check boxes are blank. The Third State check box is checked and grayed.

StepsTo enable the third state:

  1. Select the ThreeState property in the General page of the CheckBox Properties view.

StepsTo specify that a CheckBox’s current state is the third state:

  1. Select the ThreeState and the ThirdState properties in the General page of the CheckBox Properties view.