Table of contents
Collapse the table of content
Expand the table of content

Shape.SetCenter Method (Visio)

office 365 dev account|Last Updated: 6/12/2017
1 Contributor

Moves a shape so that its pin is positioned at the coordinates represented by xPos and yPos. .


expression . SetCenter( xPos , yPos )

expression A variable that represents a Shape object.


NameRequired/OptionalData TypeDescription
xPosRequiredDoubleThe new x-coordinate of the center of rotation (PinX).
yPosRequiredDoubleThe new y-coordinate of the center of rotation (PinY).

Return Value



The coordinates represented by the xPos and yPos arguments are parent coordinates, measured from the origin of the shape's parent (the page or group that contains the shape).

The SetCenter method only moves the point, in parent coordinates, about which the shape rotates. It does not change the point, in local coordinates, about which the shape rotates. The overall effect is to move the shape with respect to its parent shape (or the page).

© 2018 Microsoft