Show: Delphi C++
Display Preferences

Vcl.Menus.TMenuItem.OnClick

From RAD Studio API Documentation
Jump to: navigation, search

Delphi

property OnClick: TNotifyEvent read FOnClick write FOnClick stored IsOnClickStored;

C++

__property System::Classes::TNotifyEvent OnClick = {read=FOnClick, write=FOnClick, stored=IsOnClickStored};

Properties

Type Visibility Source Unit Parent
event published
Vcl.Menus.pas
Vcl.Menus.hpp
Vcl.Menus TMenuItem

Description

Occurs when the user clicks menu item.

Write an OnClick event handler to implement the desired behavior for when the user selects the menu item. An advantage of using the OnClick event handler over directly handling WM_COMMAND messages sent when the user selects the menu item, is that only the OnClick event occurs when the Click method is called.

Note: This event handler is not stored with the menu item if it is supplied by a TAction object.

See Also

Code Examples


Personal tools
In Other Languages
Previous Versions
Assistance