[Overview][Constants][Types][Classes][Procedures and functions][Index] | Reference for unit 'DBCtrls' (#lcl)

# TDBEdit.WndProc

Handles the specified LCL message for the control.

## Declaration

Source position: dbctrls.pp line 206

`protected procedure TDBEdit.WndProc(`
`var Message: TLMessage`
`); override;`

## Arguments

`Message` |  | LCL message examined and applied in the method.

## Description

WndProc is an overridden method in TDBEdit. It is used to process the specified LCL message for the control. WndProc ensures that the message is applied to the linked dataset when it can be modified, and handles the following LCL messages:

- LM_CLEAR
- LM_CUT
- LM_PASTE

The Edit and Modified methods in the internal TFieldDataLink instance are called, and the DataChange method is called to post changes for the control. No actions are performed on the dataset when it cannot be modified, but the result value in Message is set to 1 to prevent calling the default procedure for the window.

WndProc calls the inherited method prior to exit.

## See also

TFieldDataLink.CanModify |  | True if the linked field is capable of being modified.
TFieldDataLink.Edit |  | Edit - if the field can be modified, performs inherited Edit and shows editing status.
TFieldDataLink.Modified |  | Updates the class when the linked dataset enters an edit state.
TFieldDataLink.OnDataChange |  | Event handler signalled when the field data link has been changed.
TLMessage |  |
LM_CLEAR |  |
LM_CUT |  |
LM_PASTE |  |
TCustomEdit.WndProc |  | Suppresses the CM_CHANGED control message when an emulated TextHint is visible.