#2
Hello,

Here is an example on how to extract the coordinates of a polyline:

Code: Select all

Public Sub ShowLWPolylineCoordinates()

Dim doc As IntelliCAD.Document
Dim selEnt As IntelliCAD.entity
Dim pT1 As IntelliCAD.Point
Dim Ename As String

Set doc = IntelliCAD.ActiveDocument
doc.Utility.GetEntity selEnt, pT1, "Select a polyline: "
Ename = selEnt.EntityName

If Ename = "LightWeightPolyline" Then

   Dim selPL As IntelliCAD.LWPolyline
   Set selPL = selEnt

   Dim ptTmp As IntelliCAD.Point
   For Each ptTmp In selPL.Coordinates

      MsgBox ptTmp.x & "x" & ptTmp.y & "x" & ptTmp.z
   
   Next

End If

End Sub
Hope this helps!

Regards,
JCAMPOS
cron