AddPolyline method example


Sub AddPolylineExample()
' This example creates a Polyline  and adds it to the drawing
' using the AddPolyline method.
    Dim my3DPoly As AcadPolyline
    Dim myPoints(0 To 8) As Double
    myPoints(0) = 0: myPoints(1) = 0: myPoints(2) = 0
    myPoints(3) = 7: myPoints(4) = 2: myPoints(5) = 3
    myPoints(6) = 9: myPoints(7) = 8: myPoints(8) = 7
    Set my3DPoly = ThisDrawing.ModelSpace.AddPolyline(myPoints)
    ThisDrawing.Application.ZoomExtents
End Sub

© Bricsys NV. All rights reserved.