Explode block - Input Error

Explode block - Input Error

Anonymous
Not applicable
380 Views
2 Replies
Message 1 of 3

Explode block - Input Error

Anonymous
Not applicable
I am getting an Invalid Input error as attached. I am trying to loop
through all the blocks in a drawing, and explode to find the layers of all
items in the block.
There are approx. 860 instances of approx. 450 blocks. I have tried
objectname and objectid but they don't help isolate the problem. I tried
Insertionpoint but that is not a property of entityset.Item(i)

/snip of code

intDxfCode(0) = 0
varDxfValue(0) = "INSERT"
'set entity name DXF code to match block name
intDxfCode(1) = 2
varDxfValue(1) = oBlock.Name
Set entityset = ThisDrawing.SelectionSets.Add("SS1")
entityset.Clear
'get all instances of block name in the drawing
entityset.Select acSelectionSetAll, , , intDxfCode, varDxfValue
if entityset.count > 0 then
for i = 0 to entityset.count - 1
explodedobjects = entityset.Item(i).Explode
entityset.Item(i).Delete
next
end if

/end code snip

I am filtering my list to exclude xrefs, layouts, and block names that have
"*" in them, like *U123.

I need to know why the block won't explode but to do that I have to find
which block and where it is.
0 Likes
381 Views
2 Replies
Replies (2)
Message 2 of 3

Anonymous
Not applicable
Why are you exploding them? To find what layers a block's objects use, just
loop through the Block definition.

To answer your question, some blocks cannot be exploded.

"fieldguy" wrote in message
news:5886141@discussion.autodesk.com...
I am getting an Invalid Input error as attached. I am trying to loop
through all the blocks in a drawing, and explode to find the layers of all
items in the block.
There are approx. 860 instances of approx. 450 blocks. I have tried
objectname and objectid but they don't help isolate the problem. I tried
Insertionpoint but that is not a property of entityset.Item(i)
0 Likes
Message 3 of 3

Anonymous
Not applicable
Thank you

"Jeff Mishler" wrote in message
news:5886183@discussion.autodesk.com...
Why are you exploding them? To find what layers a block's objects use, just
loop through the Block definition.

To answer your question, some blocks cannot be exploded.

"fieldguy" wrote in message
news:5886141@discussion.autodesk.com...
I am getting an Invalid Input error as attached. I am trying to loop
through all the blocks in a drawing, and explode to find the layers of all
items in the block.
There are approx. 860 instances of approx. 450 blocks. I have tried
objectname and objectid but they don't help isolate the problem. I tried
Insertionpoint but that is not a property of entityset.Item(i)
0 Likes