Object Model Reference : Classes : S : Shape : Methods : Shape.SetSize |
Sub SetSize([Width As Double], [Height As Double])
Member of Shape
The SetSize method stretches a shape to fit a specified width and height.
• |
The shape is stretched relative to the reference point specified by the
Document.ReferencePoint property. If either parameter is omitted, the other
parameter is calculated based on the other dimension to maintain proportions.
You cannot omit both parameters, however.
|
• |
See also the Shape.SetBoundingBox method, as well as the Shape.SizeWidth
and Shape.SizeHeight properties.
|
The following VBA example resizes all shapes on the active page.
Sub Test() |
Dim s As Shape |
ActiveDocument.ReferencePoint = cdrBottomLeft |
For Each s In ActivePage.Shapes |
s.SetSize 1, 1 |
Next s |
End Sub |
Copyright 2013 Corel Corporation. All rights reserved.