Back to Devexpress

RepositoryItem.ContextMenu Property

windowsforms-devexpress-dot-xtraeditors-dot-repository-dot-repositoryitem-e8c95a6f.md

latest2.3 KB
Original Source

RepositoryItem.ContextMenu Property

Gets or sets the context menu for the editor.

Namespace : DevExpress.XtraEditors.Repository

Assembly : DevExpress.XtraEditors.v25.2.dll

NuGet Package : DevExpress.Win.Navigation

Declaration

csharp
[Browsable(false)]
[DefaultValue(null)]
[DXCategory("Behavior")]
public virtual ContextMenu ContextMenu { get; set; }
vb
<Browsable(False)>
<DXCategory("Behavior")>
<DefaultValue(Nothing)>
Public Overridable Property ContextMenu As ContextMenu

Property Value

TypeDefaultDescription
ContextMenunull

A ContextMenu object representing the context menu for the editor.

|

Remarks

Use this property to bind a context menu to the editor. Note: some editors have their own context menus provided by default. For instance, editors with text boxes provide a context menu that supports selections and Clipboard related actions etc. If a context menu is assigned to the ContextMenu property, it overrides the default context menu.

This property value is synchronized with the editor’s BaseEdit.ContextMenu property.

Changing the ContextMenu value raises the RepositoryItem.PropertiesChanged event.

Note : the context menu is not invoked if the editor is disabled.

See Also

BeforeShowMenu

RepositoryItem Class

RepositoryItem Members

DevExpress.XtraEditors.Repository Namespace