ATTRIBUTE CONVERTER?

anyone have a lisp that would assign equal attribute values to title
blocks?
TIA
Reply to
longshot
Loading thread data ...
I've got one that copies the values of one to several selected if the tags are exactly the same. Someone else wrote att-fill.lsp, which fills the same tag in several blocks with the same value. Mine is called attcopy, and is on my site. If you want the other I'll look into to see if I can find a credit, and maybe post it.
Reply to
Michael Bulatovich
Here's Att-fill....(there was no credit or claim of copyright in it): --------------------------------------------------------------------------------------- (defun c:att-fill () (setq str1 (if str1 str1 "") str1a (getstring (strcat "Attribute tag to fill : ")) str1 (if (= str1a "") str1 str1a) str2 (if str2 str2 "") str2a (getstring T (strcat "New value for Attribute : ")) str2 (if (= str2a "") str2 str2a) ) (prompt "Select objects to fill: ") (setq ss1 (ssget) count 0 ) (while (setq e1 (ssname ss1 count)) (setq elist1 (entget e1) etype1 (cdr (assoc 0 elist1)) count (1+ count) ) (if (= "INSERT" etype1) (attfil-ss e1 str1 str2)) ) (princ) )
;attribute fill selection set (defun attfil-ss (ename1 atttag attval /) (setq e2 (entnext ename1) ;select entity atttag (strcase atttag) ) ;find correct attribute (while e2 (setq elist2 (entget e2) attta1 (cdr (assoc 2 elist2)) endtest (cdr (assoc 0 elist2)) ) ;if correct attr, edits attr, else goes to next attr (if (= attta1 atttag) (progn (setq e2 nil) (entmod (subst (cons 1 attval) (assoc 1 elist2) elist2)) ; (entupd ename1) );end progn (setq e2 (entnext e2)) );end if (if (= endtest "SEQEND") (setq e2 nil) );endif );end while ) -----------------------------------------------------------------------
Reply to
Michael Bulatovich
I dont see where to DL lisps on your site...
Reply to
longshot
I think yours would work better as I just want to fill in title blocks on a job with multiple pages. I don't really see where this one would be helpful, maybe to a civil engineer on a really busy print.
---------------------------------------------------------------------------------------
Reply to
longshot
Personal>>CAD>>Lisps>>attcopy.lsp (click the name of the routine)
Reply to
Michael Bulatovich
That's exactly what this routine does, but one at a time. Better for *changes* to attribute. I often have over a dozen titleblocks to change, and att-fill does a great job. The one drag is that you have to know the *tag* of the attribute you want to change.
Reply to
Michael Bulatovich

PolyTech Forum website is not affiliated with any of the manufacturers or service providers discussed here. All logos and trade names are the property of their respective owners.