Viewer.SelectShape method (Visio Viewer)
Selects the specified shape in the drawing that is open in Microsoft Visio Viewer.
Syntax
expression.SelectShape (ShapeIndex)
expression An expression that returns a Viewer object.
Parameters
Name | Required/Optional | Data type | Description |
---|---|---|---|
ShapeIndex | Required | Long | The index in the collection of shapes of the shape to be selected. |
Return value
Nothing
Remarks
The collection of shapes is one-based, so the first shape in the collection has index number 1.
Passing 0 to the SelectShape method deselects the currently selected shape.
Example
The following code selects the shape at index position 2 in the collection of shapes in the drawing that is open in Visio Viewer.
vsoViewer.SelectShape (2)
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.