This AutoLISP function returns the
vertex of a lwpolyline (print in this case). You can use this function
in AutoLISP routines to treat lwpolylines as AutoCAD Release 13 2D
polylines.
;Coding starts here
(defun c:POINTS ()
(setq a (entget (car (entsel))) b a)
(while (/= (assoc 10 b) nil)
(print)
(princ (assoc 10 b))
(princ "\n")
(setq b (subst (cons 0 "SUBSTITUTE" (assoc 10 b) b))
)
(setq b nil)
(princ)
)