@ВeekeeCZ wrote:
Try to redraw the polyline with this routine...
....
Another [and shorter] way to accomplish the last part of that, if there are no arc segments or widths involved -- just impose the new Polyline's coordinates as a VLA Property on the original:
(vl-load-com)
(defun c:plinefrom ( / ss obj enlast ef)
(if
(and
(princ "\nSelect pattern polyline: ")
(setq ss (ssget "_+.:E:S" '((0 . "LWPOLYLINE"))))
(= 1 (sslength ss))
(setq obj (vlax-ename->vla-object (ssname ss 0)))
(setq enlast (entlast))
(princ "\nDraw new polyline: ")
(progn
(command "_.PLINE")
(while (> (getvar 'CMDACTIVE) 0) (command PAUSE))
(if (not (equal enlast (entlast))) (setq ef (entlast)))
); progn
); and
(progn ; then
(vla-put-Coordinates obj (vla-get-Coordinates (vlax-ename->vla-object ef)))
(entdel ef)
); progn
); if
(princ)
); defun
Kent Cooper, AIA