If anyone can help with this I will be greatly appreciative.
First, I create a block which has 2 atributes attached to it(length, and size) Next, I attach a block to every line in my drawing that is in a specified layer. The attributes for this block are then set to the size(width) and length of the line. The block is inserted at the midpoint of this line. This part works fine. The only problem is that if I erase all of these blocks and run the program again, every block now has 4 attributes attached to it (2 length attributes and 2 size attributes). If I do it again, each block has 6 attributes attached to it (3 length attributes and 3 size attributes) etc. etc. etc.
I can not figure out why this is happening. I am using an array of acadattributereferences when I insert these blocks so that I can store the references somewhere. Could this be a problem.
If you need actual code or if you have any suggestions at all, I would greatly appreciate any help.
Thanks,
James
First, I create a block which has 2 atributes attached to it(length, and size) Next, I attach a block to every line in my drawing that is in a specified layer. The attributes for this block are then set to the size(width) and length of the line. The block is inserted at the midpoint of this line. This part works fine. The only problem is that if I erase all of these blocks and run the program again, every block now has 4 attributes attached to it (2 length attributes and 2 size attributes). If I do it again, each block has 6 attributes attached to it (3 length attributes and 3 size attributes) etc. etc. etc.
I can not figure out why this is happening. I am using an array of acadattributereferences when I insert these blocks so that I can store the references somewhere. Could this be a problem.
If you need actual code or if you have any suggestions at all, I would greatly appreciate any help.
Thanks,
James