Sign in Join
FPDoc Onlineexperiment

TDBCheckBox.DoOnChange procedure

Member of TDBCheckBoxprotectedIn unit DBCtrls

Performs actions needed when the control is clicked.

Declaration

pascal
procedure DoOnChange; override

Description

DoOnChange is an overridden method in TDBCheckBox. It ensures that the internal TFieldDataLink is notified of a change to the control value.

If the OnDataChange event handler has been assigned for the field data link, its Edit, Modified, and UpdateRecord methods are called to store the new value for the control. If the linked dataset cannot be edited, the GetFieldCheckState method is called to get the checked state value stored to the State property.

The OnDataChange event handler in the data link is temporarily unassigned prior to updating the field value. The handler is reassigned when the actions have been completed.

DoOnChange calls the inherited method to signal the OnEditingDone and OnChange event handlers in ancestor classes.

See also

An experiment, built from development snapshots. Not the official Free Pascal or Lazarus documentation.