Make polylinebound from existing polyline

Make polylinebound from existing polyline

Anonymous
Not applicable
246 Views
1 Reply
Message 1 of 2

Make polylinebound from existing polyline

Anonymous
Not applicable
Hi,

I'm absolutely stuck, so i ask you guys for some help. I want to use an existing polyline to create a polyline bound, but i absolutely can't find how the syntax should be.
Can you guys help me?

Jan Pieter
0 Likes
247 Views
1 Reply
Reply (1)
Message 2 of 2

Anonymous
Not applicable
Jan,

 

Use the existing Polyline's ObjectID - here is
sample test sub:

 

Sub PLbound(pl As AcadEntity) 'existing
polyline
Dim acadApp As Object
Dim amap As AcadMap
Dim p As
PolylineBound
Dim pt3d As Point3D
Set acadApp =
ThisDrawing.Application
Set amap =
acadApp.GetInterfaceObject("AutoCADMap.Application")

 

Set p =
amap.Projects(ThisDrawing).MapUtil.NewPolyline(pl.ObjectID)

Dim i
For
i = 0 To p.Count - 1
    Set pt3d =
p.Item(i)
    MsgBox pt3d.X & "," &
pt3d.Y
Next

 

End Sub

 

Good Luck,

 

Scott


style="PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
Hi,

I'm absolutely stuck, so i ask you guys for some help. I want to use an
existing polyline to create a polyline bound, but i absolutely can't find how
the syntax should be.
Can you guys help me?

Jan Pieter

0 Likes