mlcadman 发表于 2022-7-6 09:51:34

Deleting un-used block attribu

I am looking for some help.. I have a program that inserts a block and within that block there are many attributes. I would like to then have my program delete the un-used attributes. Can someone get me pointed in the right direction?

David Bethel 发表于 2022-7-6 10:17:13

That's a bit dangerous.It can lead to multiple problems.
 
What is the end result that you are looking for?-David

dbroada 发表于 2022-7-6 10:27:29

why do you want to do this?
 
Once you have the block in the drawing with however many attributes you end up with, you won't be able to insert that block again with a different number of attributes. If you write the code to delete the unused attributes on insertion and your newly inserted block has fewer attributes than your previous block the previous block will be re-defined to the lower number of attributes.
 
Having said all that it shouldn't be too hard but I have forgotten all the LISP I ever knew so I'll let somebody else answer your question.

mlcadman 发表于 2022-7-6 10:40:59

I guess I didn't think about that. I dont want to do that so I will go a different direction.. Thanks

alanjt 发表于 2022-7-6 10:52:08

Just make the unused attributes blank (put "" as the text string).
页: [1]
查看完整版本: Deleting un-used block attribu