我有一个区块的SSGET,选择有效。然后,我想对每个块描述进行通配符搜索。然后我想保留带有“AAA”、“BBB”和“CCC”描述的块,并从选择中排除其他块。
一旦我有了选择,我想将选择更改为另一层。
以下是我目前掌握的情况:
- (defun c:Test ( / in ss en de myco)
- (setq myco 0)
- (if (setq in -1 ss (ssget "_C" '(7.244 2.071) '(16.665 10.003) '((0 . "INSERT") (8 . "FTG-Iso"))))
- (while (setq en (ssname ss (setq in (1+ in))))
- (progn
- (setq myco (+1 myco))
- (princ (strcat "\n " (rtos myco 2 0) ". Hey!"))
- (setq de (entget en description))
- ; (princ (strcat "\n " de))
- [color=blue]{Exclude entities that do not have valid strings in description}[/color]
- )
- )
- )
- (sssetfirst nil ss)
- (princ)
- )
Greg |