![]() |
![]() |
NodeRange.Item
Property Item(Index As Long) As Node
Member of NodeRange
The Item property returns the specified Node object from the NodeRange object.
The Item property is the default property and its reference can be omitted when accessing items in the range. For example, NodeRange.Item(2)
is the same as NodeRange(2)
they both reference the second node in the range.
The Item property returns a read-only value.
The following code example creates a node range from all nodes in the curve, and it removes all symmetrical and smooth nodes from the range (although it does not delete the nodes from the curve). The remaining collection of cusp nodes is rotated by 30? relative to its geometric center.
Sub Test() Dim nr As NodeRange Dim n As Node Dim i As Long Set nr = ActiveShape.Curve.Nodes.All For i = nr.Count To 1 Step -1 If nr.Item(i).Type <> cdrCuspNode Then nr.Remove i ' The same as: If nr(i).Type <> cdrCuspNode Then nr.Remove i Next i ActiveDocument.ReferencePoint = cdrCenter If nr.Count > 0 Then nr.Rotate 30 End Sub
![]() |
![]() |
![]() |
Copyright 2007 Corel Corporation. All rights reserved.