Show / Hide Table of Contents

Class CommandBarPopup

Corresponds to a menu popup (or a toolstrip inside a menu)

Inheritance
object
CommandBarControl
CommandBarPopup
CommandBarContextPopup
CommandBarGalleryPopup
Implements
ICommandBarControlContainer
Inherited Members
CommandBarControl.ToString()
CommandBarControl.ResolveTarget(IEnumerable<Delegate>)
CommandBarControl.Id
CommandBarControl.Caption
CommandBarControl.Image
CommandBarControl.ImagePlacement
CommandBarControl.LargeImage
CommandBarControl.Tag
CommandBarControl.HelpText
CommandBarControl.ScreenTipImage
CommandBarControl.HelpId
CommandBarControl.Visible
CommandBarControl.IsUndoable
CommandBarControl.ThemedImage
CommandBarControl.LargeThemedImage
CommandBarControl.TrackCommandBarControl
Namespace: ABB.Robotics.RobotStudio.Environment
Assembly: ABB.Robotics.RobotStudio.Environment.dll
Syntax
public class CommandBarPopup : CommandBarControl, ICommandBarControlContainer

Constructors

View Source

CommandBarPopup(string)

Creates a CommandBarPopup with a specific ID.

Declaration
public CommandBarPopup(string id)
Parameters
Type Name Description
string id

Control ID

Remarks

The ID will be set as the popup's caption as well.
Prefix the ID with the name of your Add-In, to avoid conflicts.

See Also
CommandBarControl
View Source

CommandBarPopup(string, string)

Creates a CommandBarPopup with a specific ID and caption.

Declaration
public CommandBarPopup(string id, string caption)
Parameters
Type Name Description
string id

Control ID

string caption

Control caption

Remarks

The ID can be null, which creates a popup that will not be added to the UIEnvironment.CommandBarControls collection.
If you specify an ID, prefix it with the name of your Add-In, to avoid conflicts.

See Also
CommandBarControl
View Source

CommandBarPopup(string, string, params CommandBarControl[])

Creates a CommandBarPopup with a specific ID, caption and child controls

Declaration
public CommandBarPopup(string id, string caption, params CommandBarControl[] controls)
Parameters
Type Name Description
string id

Control ID

string caption

Control caption

CommandBarControl[] controls

Child controls

Remarks

The ID can be null, which creates a popup that will not be added to the UIEnvironment.CommandBarControls collection.
If you specify an ID, prefix it with the name of your Add-In, to avoid conflicts.

See Also
CommandBarControl

Properties

View Source

ClickButton

The button whose command will be executed when the button part of the popup is clicked.

Declaration
public CommandBarButton ClickButton { get; set; }
Property Value
Type Description
CommandBarButton
Remarks

Currently not supported for CommandBarButtons that are part of menus.

View Source

Controls

Gets a collection of all child CommandBarControls contained by this popup

Declaration
public CommandBarControlCollection Controls { get; }
Property Value
Type Description
CommandBarControlCollection
View Source

Enabled

Gets or sets if the popup should be enabled or not, or if that status should be controlled by its children.

Declaration
public CommandBarPopupEnableMode Enabled { get; set; }
Property Value
Type Description
CommandBarPopupEnableMode
View Source

HasEnabledItems

Returns True if the popup has at least one enabled item.

Declaration
public virtual bool HasEnabledItems { get; }
Property Value
Type Description
bool
View Source

IsEnabled

Gets if the popup should be enabled according to to Enabled and HasEnabledItems properties.

Declaration
public bool IsEnabled { get; }
Property Value
Type Description
bool
View Source

ShowDisabledItems

If True, disabled items are shown grayed out, otherwise they are not shown at all. Default is True.

Declaration
public bool ShowDisabledItems { get; set; }
Property Value
Type Description
bool
View Source

ShowFilter

Display a text box for filtering long lists of popup items.

Declaration
public bool ShowFilter { get; set; }
Property Value
Type Description
bool
Remarks

Currently not supported for gallery popups.

Methods

View Source

FromID(string)

Returns the CommandBarPopup that has the specified ID, or null if none exists.

Declaration
public static CommandBarPopup FromID(string id)
Parameters
Type Name Description
string id

ID to find popup for

Returns
Type Description
CommandBarPopup

The CommandBarPopup with the specified ID

Remarks

This is the same as UIEnvironment.CommandBarControls[id] as CommandBarPopup

View Source

Show(int, int)

Displays the popup at the given position in screen coordinates

Declaration
public void Show(int x, int y)
Parameters
Type Name Description
int x
int y

Events

View Source

UpdateContent

Occurs before the popup's list of menu items is displayed or when the framework needs to determine if the popup should be grayed out or not

Declaration
public event EventHandler UpdateContent
Event Type
Type Description
EventHandler
Remarks

Allows you to modify the menu popup's content before it is displayed, as a more powerful alternative to using a CommandBarButtonGroup.

Implements

ICommandBarControlContainer
  • View Source
In this article
Back to top Copyright © 2025 ABB