Move location of Mleader text

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
I am trying to create a routine to allow user to cycle thru all mleader in drawing and allow user to move text location.
Here was what I have -
(defun C:MML ()
(if (setq SSttm (ssget "X" (list (cons 0 "MULTILEADER"))))
(progn
(setq KK 0)
(while (< KK (sslength SSttm))
(setq Mobj (vlax-ename->vla-object (ssname SSttm KK)))
(setq Tlab (vla-get-TextString Mobj))
(setq EG (entget (ssname SStti KK))) ;prefer to use vla-
(setq P1 (cdr (assoc 110 EG))) ;can't figure out how to get leader arrowhead location point
(setq P2 (cdr (assoc 10 EG))) ;can't figure out how to get leader landing location point
(redraw (cdr (assoc -1 EG)) 3)
(command "ZOOM" "C" P2 "")
(setq P3 (getpoint P1 "Pick NEW Location for Mleader Text ? "))
(if (and P3 (not (equal P3 P2)))
(progn
;area of code to modify
(getstring "?")
)
)
(redraw (cdr (assoc -1 EG)) 4)
(if (and Mobj (not (vlax-object-released-p Mobj))) (vlax-release-object Mobj))
(setq KK (1+ KK))
)
)
)
(princ)
)