Skip to content

AddHiddenCommand Method

Description

Adds the specified command as a hidden command, i.e., an infrequently used command.

Syntax

Public Sub AddHiddenCommand( _
    ByVal [Command] As Long _
)

Parameters

  • Command: The ID of the command that will be hidden.

Remarks

The command will not be displayed in popup menus until the user clicks on the "expand menu" button or after a short delay when ShowFullAfterDelay is true. Note: AlwaysShowFullMenus must be set to False to hide the hidden commands.

Example

AddHiddenCommand Sample (Visual Basic)

This sample code illustrates how to add hidden commands.

' This will allow commands to be shown as hidden in the popup menus  
CommandBars.Options.AlwaysShowFullMenus = False  

' This will add 3 hidden commands, they will become visible when the  
' expand button is pressed or after a short delay  
CommandBars.Options.AddHiddenCommand (ID_FILE_SAVE)  
CommandBars.Options.AddHiddenCommand (ID_FILE_CLOSE)  
CommandBars.Options.AddHiddenCommand (ID_FILE_SAVE_AS)  

See Also


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