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

# TMaskEdit.OnKeyDown

Handles a key down event for the focused control.

## Declaration

Source position: maskedit.pp line 376

`published property TMaskEdit.OnKeyDown : TKeyEvent;`

## Description

OnKeyDown is an event handler signalled when a key is down while control has focus.

Differs from OnKeyPress in that the key may have already been down when the control received focus; with OnKeyPress the key needs to become pressed while the control has focus.

## See also

TWinControl.OnKeyDown |  | Event handler signalled for key down keyboard events.