(defun c:POV (/ foo ss)
;; Points On Vertices (create points on vertices of selected Arcs, Lines, *Polylines, Splines)
;; Alan J. Thompson, 09.09.10 / 09.22.10
;; Modified by Tharwat - Date: 04.Jul.19
(defun foo (p)
(if (vl-consp p)
(or (vl-member-if (function (lambda (a) (equal (list (car a) (cadr a)) (list (car p) (cadr p))))) plst)
(setq plst (cons (cdr (assoc 10 (entmake (list '(0 . "POINT") '(8 . "Points") (cons 10 p))))) pLst))))
)
(if (setq ss (ssget '((0 . "ARC,LINE,*POLYLINE,SPLINE,CIRCLE"))))
((lambda (i / e eLst p pLst)
(while (setq e (ssname ss (setq i (1+ i))))
(cond
((vl-position (cdr (assoc 0 (setq eLst (entget e)))) '("ARC" "LINE" "SPLINE"))
(mapcar (function foo) (list (vlax-curve-getStartPoint e) (vlax-curve-getEndPoint e)))
)
((vl-position (cdr (assoc 0 eLst)) '("LWPOLYLINE" "POLYLINE"))
(repeat (setq p (1+ (fix (vlax-curve-getEndParam e))))
(foo (vlax-curve-getPointAtParam e (setq p (1- p))))
)
)
(t (mapcar (function foo) (list (cdr (assoc 10 eLst))))
)
)
)
)
-1
)
)
(princ)
)