Vcl.DBCtrls.TDBEdit.OnEnter

From RAD Studio API Documentation
Jump to: navigation, search

Delphi

property OnEnter: TNotifyEvent read FOnEnter write FOnEnter;

C++

__property OnEnter;

Properties

Type Visibility Source Unit Parent
event published
Vcl.DBCtrls.pas
Vcl.DBCtrls.hpp
Vcl.DBCtrls TDBEdit

Description

Occurs when a control receives the input focus.

Vcl.DBCtrls.TDBEdit.OnEnter inherits from Vcl.Controls.TWinControl.OnEnter. All content below this line refers to Vcl.Controls.TWinControl.OnEnter.

Occurs when a control receives the input focus.

Use the OnEnter event handler to cause any special processing to occur when a control becomes active.

The OnEnter event does not occur when switching between forms or between another application and the application that includes the control.

When switching between controls in separate container controls such as the TPanel and the TGroupBox controls, an OnEnter event occurs for the container before the OnEnter event of the contained control.

Similarly, an OnExit event of the container occurs after the OnExit event of the control in a container when focus moves to another control outside the container.

For example, consider a form with an OK button and a group box that contains three radio buttons, where focus is currently on the OK button. When the user clicks one of the radio buttons, an OnExit event of the button occurs, followed by an OnEnter event on the group box, and finally an OnEnter event on the radio button that was clicked. If the user then clicks on the OK button, an OnExit event for the radio button occurs followed by an OnExit event for the group box, and then the button's OnEnter event occurs.

OnEnter is an event handler of type System.Classes.TNotifyEvent.

See Also

Code Examples