how can i select a series of blocks based upon attribute data -- such as
selecting room tags based on the value "toilet" within the tag?
thanks in advance!
joe eichenseer
weller architects
> how can i select a series of blocks based upon attribute data -- such as
> selecting room tags based on the value "toilet" within the tag?
ToolPac 4.0's Attribute Find will find text in selected tags and zoom center
for identification. Includes interactive selection set building
capabilities.
Follow the URL below to find out more.
Thanks, Terry
o---------------------------------------------o
| ToolPac 4.0, a 400+ function collection |
| of Power Tools for all AutoCAD users. |
| Visit http://www.dotsoft.com for details. |
o---------------------------------------------o
Cabot
joe eichenseer wrote:
>
> i know that this should be able to be done by LISP, but i have not yet
> found the time to learn....
>
> how can i select a series of blocks based upon attribute data -- such as
> selecting room tags based on the value "toilet" within the tag?
>
> thanks in advance!
>
> joe eichenseer
> weller architects
--
Mark Eudaley Engineers, Inc.
me...@ionet.net
(remove NOSPAM from reply to)
> Try the FILTER command. Allows you to 'filter' out things
> you haven't specified. Plus you can save filters to use on
> several drawings.
But there is no 'Attribute Value' field, which is what the original poster
wanted to do. I won't deny that FILTER has merit (and problems), but I don't
think it works in this case.
Regards, Terry
Hope that helps.
Thanks,
- Randy
Randy Kintzley
AutoCAD Express Tools Developer (formerly Bonus Tools)
randy.k...@autodesk.com
http://www.autodesk.com/expresstools
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
(defun c:attselect ( / ss2 ss tag val n na)
(setq ss2 (ssadd))
(sssetfirst nil nil)
(princ "\nSelect blocks containing attributes.")
(if (setq ss (ssget '((0 . "INSERT") (66 . 1))))
(progn
(setq tag (getstring "\nEnter the TAG search specification <*>: ")
val (getstring T "\nEnter the VALUE search specification <*>:
")
);setq
(if (equal tag "")
(setq tag "*")
);if
(if (equal val "")
(setq val "*")
);if
(setq n 0)
(repeat (sslength ss)
(setq na (ssname ss n))
(if (sample_att_match na tag val)
(setq ss2 (ssadd na ss2))
);if
(setq n (+ n 1));setq
);repeat
(if (equal (getvar "cmdnames") "")
(sssetfirst ss2 ss2)
(command ss2)
);if
);progn then
);if
(princ)
);defun c:attselect
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
(defun sample_att_match ( na tag val / e1 a b flag)
(while (and (setq na (entnext na))
(setq e1 (entget na))
(not (equal (cdr (assoc 0 e1)) "SEQEND"))
(not flag)
);and
(if (equal (cdr (assoc 0 e1)) "ATTRIB")
(progn
(setq a (cdr (assoc 2 e1)) ;2 is tag
b (cdr (assoc 1 e1)) ;1 is value
);setq
(if (and a
(wcmatch a tag)
b
(wcmatch b val)
);and
(setq flag T);then jump out of the loop
);if
);progn then attrib
);if
);while
flag
);defun sample_att_match
(princ "\nType ATTSELECT to run")
(princ)
Keith
Cabot Eudaley wrote in message <359000D1...@ionet.net>...
>Try the FILTER command. Allows you to 'filter' out things
>you haven't specified. Plus you can save filters to use on
>several drawings.
>
>Cabot
>
Thanks for saying thanks.
It makes it all worth while. :)
On Wed, 24 Jun 1998 08:24:41 -0600, joe eichenseer <wel...@flash.net>
wrote:
>Thanks!!!
>-joe
>
(snip)
regards,
joe