(defun c:test ( / e i j m n p s PFX FILLSTR)
(defun FILLSTR(STR ANZ)
(while (<(strlen STR)ANZ)(setq STR(strcat "0" STR)))
STR
)
(setq PFX (getstring "\nPrefix"))
(if (setq s (ssget '((0 . "LWPOLYLINE"))))
(repeat (setq i (sslength s))
(setq e (ssname s (setq i (1- i)))
n (cdr (assoc 210 (entget e)))
m (vlax-curve-getendparam e)
j -1
)
(while (<= (setq j (1+ j)) m)
(setq p (trans (vlax-curve-getpointatparam e j) 0 e))
(entmakex
(list
(cons 0 "TEXT")
(cons 7 (getvar 'TEXTSTYLE))
(cons 40 (getvar 'TEXTSIZE))
(cons 10 p)
(cons 11 p)
(cons 72 1)
(cons 73 2)
(cons 1 (strcat PFX(FILLSTR(itoa (1+ j))3)))
(cons 210 n)
)
)
)
)
)
(princ)
)
------------------
Also ich finde Unities gut ... und andere sicher auch
---------------------------------------
- Thomas -
"Bei 99% aller Probleme ist die umfassende Beschreibung des Problems bereits mehr als die Hälfte der Lösung desselben."
Eine Antwort auf diesen Beitrag verfassen (mit Zitat/Zitat des Beitrags) IP