appevents OnActionUpdate event
Return to Introduction  Previous page  Next page
Applies to
acAppEvents component.  

Declaration
type  
  TActionEvent = procedure(Action: TBasicAction; var Handled: Boolean) of object;  
 
property OnActionUpdate: TActionEvent;  

Description
The OnActionUpdate event occurs when an action's Update method is called and its action list has not already handled it.  
 
Use the OnActionUpdate event handler to update the properties of an action when the application is idle if the action's action list does not handle it in an OnUpdate event handler.  
 
If the action list that contains the action does not update it in an OnUpdate event handler, the action is routed to the Application object's UpdateAction method, which invokes the OnActionUpdate event handler. (The application's UpdateAction method applies to all actions in the application.)  
 
The Handled parameter of the event handler returns False by default. If the handler updates the event, it should change Handled to True, thereby ending the processing of the action. When the event handler exits with Handled set to False, the action's OnUpdate event occurs. If the action is not updated after that, the active control's UpdateAction method is called to allow the target to update the action. Finally, the active form's UpdateAction method is called if all other handlers do not handle the action.  

Notes
iiinfo OnActionUpdate occurs after the application's OnIdle event.  
The OnActionExecute and OnActionUpdate events available in Delphi 4/BCB 4 and higher.  

See also
OnActionExecute, OnIdle event.