IMenuCommandService.ShowContextMenu(CommandID, Int32, Int32) Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Shows the specified shortcut menu at the specified location.
public:
void ShowContextMenu(System::ComponentModel::Design::CommandID ^ menuID, int x, int y);
public void ShowContextMenu (System.ComponentModel.Design.CommandID menuID, int x, int y);
abstract member ShowContextMenu : System.ComponentModel.Design.CommandID * int * int -> unit
Public Sub ShowContextMenu (menuID As CommandID, x As Integer, y As Integer)
Parameters
- x
- Int32
The x-coordinate at which to display the menu, in screen coordinates.
- y
- Int32
The y-coordinate at which to display the menu, in screen coordinates.
Remarks
The ShowContextMenu method can display any of the following Visual Studio shortcut menus containing menu commands at a specified point:
Menu | CommandID |
---|---|
The shortcut menu displayed for a container | ContainerMenu |
The shortcut menu displayed for the component tray | ComponentTrayMenu |
The shortcut menu displayed for a selection | SelectionMenu |
The shortcut menu displayed for a tray selection | TraySelectionMenu |
This method can also display other registered shortcut menus.
Applies to
See also
Feedback
https://aka.ms/ContentUserFeedback.
Coming soon: Throughout 2024 we will be phasing out GitHub Issues as the feedback mechanism for content and replacing it with a new feedback system. For more information see:Submit and view feedback for