Hi,
Please find below a crude sample code which converts a
3dpolyline to a standard polyline
(defun c:fn(/ a-app a-doc a-msp ent etype lwp)
(setq
a-app (vlax-get-acad-object)
a-doc (vla-get-ActiveDocument
a-app)
a-msp (vla-get-ModelSpace a-doc)
ent
(vlax-ename->vla-object (car (entsel "Select a 3D Polyline:
")))
etype (vla-get-objectname ent)
)
(if (/=
etype "AcDb3dPolyline")
(progn
(alert "Invalid
entity.")
(exit)
)
)
(setq lwp (vla-AddPolyline a-msp (vla-get-coordinates
ent)))
)
Hope this helps
Thilak