The DBCheckBox component is a data-aware check box control used for input and representation of Boolean or other logical fields in a dataset. Unique to this control is that it does not strictly require that the values in the database be True or False. Using the ValueChecked and ValueUnchecked properties, your application can select any pair of characters or strings to represent the two states of the control. Using the attribute based on the values that best represent the data you are modeling will build a great deal of flexibility into your Delphi solutions.
The check box is a highly intuitive interface element that allows the user to quickly represent one of two states. Since the value written to the dataset does not have to be strictly True or False, the application can use this component anyplace that a coded response is necessary. This saves the user from having to remember codes for the dataset or translate visual cues on the form into the necessary string.
Was this article helpful?