Share

CommandControls Object


Description

The CommandControls collection object provides access to a collection of user interface controls and provides methods to create additional controls.

Methods

Name Description
AddButton Method that creates a new button CommandControl object. An example of this type of control is the 'Extrude' feature command button.
AddButtonPopup Method that creates a new popup CommandControl object. An example of this type of control is the 'Display Mode' drop down (Shaded, Hidden Edge, Wireframe) available on the 'View' tab of the ribbon in parts and assemblies.
AddComboBox Method that creates a new combo-box CommandControl object.
AddCopy Method that creates a copy of an existing CommandControl object as a child control of the current CommandControl. This can be used to copy controls between ribbon panels.
AddGallery Method that creates a new gallery CommandControl object. An example of this type of control is the gallery control available in the Symbols panel of the Annotate tab in drawings.
AddMacro Method that creates a new macro CommandControl object.
AddPopup Method that creates a new popup CommandControl object. An example of this type of control is the 'Switch' control available in the Windows panel of the View tab.
AddSeparator Method that creates a new separator CommandControl object.
AddSplitButton Method that creates a new split button CommandControl object. An example of this type of control is the 'New File' split button drop down available in the Quick Access Toolbar.
AddSplitButtonMRU Method that creates a new split button MRU (Most Recently Used) CommandControl object. An example of this type of control is the 'Circle' drop down in the Sketch tab of the ribbon.
AddTogglePopup Method that creates a new toggle popup CommandControl object. An example of this type of control is the 'Object Visibility' control available in the Visibility panel of the Views tab.

Properties

Name Description
Application Returns the top-level parent application object. When used the context of Inventor, an Application object is returned. When used in the context of Apprentice, an ApprenticeServer object is returned.
Count Property that returns the number of items in this collection.
Item Returns the specified CommandControl object from the collection.
Type Returns an ObjectTypeEnum indicating this object's type.

Accessed From

CommandControl.ChildControls, Ribbon.QuickAccessControls, RibbonPanel.CommandControls, RibbonPanel.SlideoutControls, UserInterfaceManager.FileBrowserControls, UserInterfaceManager.HelpControls

Samples

Name Description
Add commands to the application menu Demonstrates adding command to the application menu.
Add parallel environment with contextual tabs The following sample demonstrates the use of parallel environments and contextual ribbon tabs.
Print information about all available ribbons. This sample prints out all of the elements of the ribbons. This output is very useful when customizing the ribbon to be able to get the names of the various existing ribbons, tabs, and panels.
Creation of an override environment for a document A new ribbon tab is created and associated with the override environment.
Create a ribbon panel in an existing tab Demonstrates creating a new ribbon panel within an existing ribbon tab.

Version

Introduced in version 2010

Was this information helpful?