Message 1 of 13
How to get anonymous blocks' name?
Not applicable
01-09-2007
03:39 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
Hi all,
I am writing some code to solve this:
I have a drawing containing simple blocks and "compound" blocks (blocks composed by smaller blocks). I prompt the user to select a block. If the block is a simple one, I simply show its name. Otherwise, I have to get the names of its sub-blocks and show them to the user.
When I thought I got it, I saw that when exploding some compound blocks (using AcDbEntity::explode()), some of the entities returned are anonymous blocks (*U80, *U67, ...). I tried to get its name reading BlockTableRecord, but I get the anonymous autogenerated name. I checked if the blocks are dynamic (so as to take its name from DynamicBlockTableRecord), but they aren't.
Can anybody help me?
P.S.: I am using AutoCAD 2006 and ObjectARX 2006
Thanks in advance 🙂
I am writing some code to solve this:
I have a drawing containing simple blocks and "compound" blocks (blocks composed by smaller blocks). I prompt the user to select a block. If the block is a simple one, I simply show its name. Otherwise, I have to get the names of its sub-blocks and show them to the user.
When I thought I got it, I saw that when exploding some compound blocks (using AcDbEntity::explode()), some of the entities returned are anonymous blocks (*U80, *U67, ...). I tried to get its name reading BlockTableRecord, but I get the anonymous autogenerated name. I checked if the blocks are dynamic (so as to take its name from DynamicBlockTableRecord), but they aren't.
Can anybody help me?
P.S.: I am using AutoCAD 2006 and ObjectARX 2006
Thanks in advance 🙂