on error resume advice

on error resume advice

Anonymous
Not applicable
194 Views
0 Replies
Message 1 of 1

on error resume advice

Anonymous
Not applicable
I have this code but don't understand why it won't work:

Dim ABlock As AcadBlock
On Error Resume Next
Set ABlock = Database.Blocks(Name)
If Err Then
Err.Clear
Exit Sub
End If

When the block I'm searching for "Name" isn't present I get a "Key Not
Found" error.
0 Likes
195 Views
0 Replies
Replies (0)