Skip to main content

RibbonControl.SetPopupContextMenu(Control, PopupMenuBase) Method

Sets a specific PopupMenuBase object as the target control’s pop-up.

Namespace: DevExpress.XtraBars.Ribbon

Assembly: DevExpress.XtraBars.v23.2.dll

NuGet Package: DevExpress.Win.Navigation

Declaration

public void SetPopupContextMenu(
    Control control,
    PopupMenuBase menu
)

Parameters

Name Type Description
control Control

A Control to be associated with a pop-up.

menu PopupMenuBase

A PopupMenuBase object to be made the control‘s pop-up menu.

Remarks

The SetPopupContextMenu method associates a pop-up menu managed by the current RibbonControl with any Control on a form. A control’s pop-up menu can be invoked at runtime with a left mouse-click.

Use the PopupMenuBase.Ribbon property to set a RibbonControl that will manage this PopupMenuBase object.

See Also