Skip to content

Add Method

Description

Adds a CommandBarAction to the command bars collection of actions.

Syntax

Public Function Add( _
    ByVal [Id](#) As Long, _
    ByVal [Caption](#) As String, _
    ByVal [TooltipText](#) As String, _
    ByVal [DescriptionText](#) As String, _
    ByVal [Category](#) As String _
) As [CommandBarAction](XtremeCommandBars~CommandBarAction.md)

Parameters

  • Id: Id of the CommandBar items that will use this action.
  • Caption: Text caption of the items that use this action.
  • TooltipText: Tooltip for items that use this action.
  • DescriptionText: Text displayed in the status bar when using a custom status bar. This text will automatically be displayed in the status bar pane with Id=0 on mouse over.
  • Category: Category of the items that use this action. The category is used for items that are added to the DesignerControls collection in the Customization event and determines how the items are categorized in the Customization dialog.

Return Type

Returns a reference to the CommandBarAction that was just added.

Remarks

EnableActions must be called to enable actions to be used. Each CommandBar Item has an Action property which is just a reference to the CommandBars Action item that is associated with it. If no action is added for an item or actions have not been enabled, the default properties of the item will be used.

See Also


See Also


Copyright (c) 1998-2024 Codejock Technologies. All rights reserved.