Previous Document Next Document
ShapeRange.PositionY

Property PositionY As Double

Member of ShapeRange

The PositionY property returns or sets the y-coordinate of a range of shapes, treating the group of shapes as a single object. The coordinate is specified relative to the anchor point specified by the Document.ReferencePoint property.

See also the GetPosition, SetPosition, Move, GetBoundingBox, and SetBoundingBox methods.

The following code example creates a range containing all of the ellipses on the page and duplicates the range. The duplicated shapes are placed in the lower-left corner of the page, treating the group of shapes as a group.

Sub Test() 
 Dim sr1 As ShapeRange, sr2 As ShapeRange 
 Set sr1 = ActivePage.FindShapes(Type:=cdrEllipseShape) 
 Set sr2 = sr1.Duplicate 
 ActiveDocument.ReferencePoint = cdrBottomLeft 
 sr2.PositionX = 0 
 sr2.PositionY = 0 
End Sub 

Previous Document Next Document Back to Top

Copyright 2007 Corel Corporation. All rights reserved.