0 Members and 1 Guest are viewing this topic.
What i need is alittle more then just a Justify Text routine....I need to find a string of text with a certain value and only that value...change the justification to left and change the widthfactor to 1...I have like 400 drawings I need to do this too...and really dont want to do it manually...any help would be mucho appreciated...Thanks!
(defun c:FixText ( / ss ) (if (setq ss (ssget "_X" '((0 . "TEXT") (1 . "YourStringHere")))) ( (lambda ( x / e ) (while (setq e (ssname ss (setq x (1+ x)))) (Update (SubstDXF 72 0 (SubstDXF 73 0 (SubstDXF 41 1 (entget e)) ) ) ) ) ) -1 ) ) (princ))(defun SubstDXF ( code value elist ) ;; © Lee Mac 2010 (if elist (entmod (subst (cons code value) (assoc code elist) elist ) ) ))(defun Update ( elist ) ;; © Lee Mac 2010 (if elist (entupd (cdr (assoc -1 elist)))))
(load "FixText.lsp" nil) (c:FixText)
that works perfectly. I wish I was as smart as some of you.