API Documentation > CorelDRAW > 2025-v26 > NodeRange > IVGNodeRange
NodeRange.PositionY property
Gets the Y position of the topmost node within the range
Syntax:
Property Get PositionY() As Double
Remarks:
The PositionY property returns the vertical position of the bounding box that encloses all nodes in a node range. This position is relative to the document's reference point and is measured in document units. The value of PositionY is 0 if there are no nodes in the node range.
Examples:
The following VBA example draws a rectangle around the selected nodes.
Sub Test()
Dim nr As NodeRange
Dim x1 As Double, y1 As Double
Dim x2 As Double, y2 As Double
Set nr = ActiveShape.Curve.Selection
ActiveDocument.ReferencePoint = cdrTopLeft
x1 = nr.PositionX
y1 = nr.PositionY
ActiveDocument.ReferencePoint = cdrBottomRight
x2 = nr.PositionX
y2 = nr.PositionY
ActiveLayer.CreateRectangle x1, y1, x2, y2 
End Sub