Action Property
Description
Collection of CommandBarAction objects that have been added to the command bars collection of actions.
Property type
Read-only property
Syntax (Visual Basic)
Public Property Action(ByVal Id As Long) As CommandBarAction
Parameters
- Id — Id of the CommandBarAction to return.
Remarks
EnableActions must be called to enable actions. Each CommandBar item has an Action property which is a reference to the associated CommandBarAction. If no action is added for an item or actions have not been enabled, the default properties of the item will be used.
The Action collection allows you to add and access CommandBarAction items for your CommandBars items.
CommandBar actions eliminate the need to use the Update event to update/change the state and properties of an item that appears in multiple places (for example, a menu item that also appears in a toolbar). If a user places the same button in multiple locations, modifying the associated action updates all occurrences of the item.
See Also
Example
Copyright (c) 1998-2024 Codejock Technologies. All rights reserved.