Object Model Reference : Classes : N : NodeRange : Methods : NodeRange.Move |
Sub Move([DeltaX As Double], [DeltaY As Double], [AnchorIndex As Long = 1], [ElasticMode As Boolean = False])
Member of NodeRange
The Move method repositions all nodes in a node range by moving each node by a specified offset.
The following VBA example creates a node range from all nodes in the curve except for the first and the last nodes. The nodes are then moved up (vertically) by 1" and moved back down by 1" with Elastic Mode enabled. The middle node (node_count/2) is used as an anchor node in the last operation.
Sub Test() |
Dim crv As Curve |
Dim nr As NodeRange |
Set crv = ActiveShape.Curve |
Set nr = crv.Nodes.AllExcluding(1, crv.Nodes.Count) |
nr.Move 0, 1 |
nr.Move 0, -1, nr.Count \ 2, True |
End Sub |
Copyright 2013 Corel Corporation. All rights reserved.