Previous Document Next Document

Object Model Reference : Classes : S : Shape : Methods : Shape.SetPosition


Shape.SetPosition

Sub SetPosition(PositionX As Double, PositionY As Double)

Description

Member of Shape

The SetPosition method moves a shape to a given position on the page. The specified coordinates of the new position are relative to the shape’s reference point, as specified by the Document.ReferencePoint property.

Parameter
Description
PositionX
Specifies, in document units, the horizontal position of the shape
PositionY
Specifies, in document units, the vertical position of the shape

VBA example

The following VBA example sets the current position of each shape on the page to the bottom-left corner of the page.

Sub Test()
 Dim s As Shape
 Dim x As Double, y As Double
 For Each s In ActivePage.Shapes
  s.SetPosition 0, 0
 Next s
End Sub

Previous Document Next Document Back to Top

Copyright 2013 Corel Corporation. All rights reserved.