AddRay method example


Sub AddRay_Example()
' This example creates an infinite half line and adds it to the drawing using the
' AcadRay method.
     Dim myRay As AcadRay
     Dim Pt1(0 To 2) As Double
     Dim Pt2(0 To 2) As Double
     Pt1(0) = 2: Pt1(1) = 2: Pt1(2) = 0
     Pt2(0) = 1: Pt2(1) = 3: Pt2(2) = 0
     Set myRay = ThisDrawing.ModelSpace.AddRay(Pt1, Pt2)
     ThisDrawing.Application.ZoomExtents
End Sub

© Bricsys NV. All rights reserved.