Viewer.DisplayContextMenu method (Visio Viewer)

Displays the shortcut menu for Microsoft Visio Viewer at the specified screen coordinates, in pixels.

Syntax

expression.DisplayContextMenu (ScreenX, ScreenY)

expression An expression that returns a Viewer object.

Parameters

Name Required/Optional Data type Description
ScreenX Required Long The x-coordinate, in pixels, of the point where the menu should appear, relative to the origin of the frame of the screen.
ScreenY Required Long The y-coordinate, in pixels, of the point where the menu should appear, relative to the origin of the frame of the screen.

Return value

Nothing

Remarks

Use the ScreenX and ScreenY parameters to specify the coordinates of the point where you want the shortcut menu to appear, relative to the origin of the frame of the screen. The origin of the screen frame is in the upper-left corner.

Example

The following code specifies that the shortcut menu appear at screen coordinates (300, 300).

vsoViewer.DisplayContextMenu(300,300)

Support and feedback

Have questions or feedback about Office VBA or this documentation? Please see Office VBA support and feedback for guidance about the ways you can receive support and provide feedback.