Version

ContextMenuInitializing Event

Fired before the control's custom ContextMenu is displayed.
Syntax
'Declaration
 
Public Event ContextMenuInitializing As ContextMenuInitializingHandler
public event ContextMenuInitializingHandler ContextMenuInitializing
Event Data

The event handler receives an argument of type ContextMenuInitializingEventArgs containing data related to this event. The following ContextMenuInitializingEventArgs properties provide information specific to this event.

PropertyDescription
Area Returns the area of the control from which the display of the menu was triggered.
Cancel (Inherited from System.ComponentModel.CancelEventArgs) 
ContextMenu Returns or sets the ContextMenu that will be assigned to the control's ContextMenu property if the event is not canceled.
DefaultContextMenu Returns GanttViewContextMenu that is displayed by default if the event is not canceled.
Location Returns the coordinates of the right-click that caused the menu to be displayed.
Task Returns the Task that provides context for the menu, or null if there is no active task.
Requirements

Target Platforms: Windows 10, Windows 8.1, Windows 8, Windows 7, Windows Server 2012, Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

See Also