- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
Greetings!
If there is a specific drawing file created with the "WBLOCK" command (the name of the block is equal to the name of the dwg file that contains only this block).
How to import such a block, but DO NOT insert the block into the drawing (ONLY IMPORT).
I tried to use the vla-InsertBlock function, specifying InsertionPoint - nil as an argument, thus:
(vla-InsertBlock (vla-get-modelspace (vla-get-activedocument (vlax-get-acad-object))) nil (strcat "Block_Name" ".dwg") 1 1 1 0)
In such a case, the block will be imported into the drawing, but the function evaluation will return an error.
Adding to the expression:
(vl-catch-all-error-p (vl-catch-all-apply ...)) does not fix the error.
So my question is: how can I import a block from an external file without error? I would not like to use for this command method.
My second question.
If the block exists in the drawing:
(tblsearch "BLOCK" "Block_Name")
then I can determine if the block has attributes:
(= 2 (cdr (assoc 70 (tblsearch "BLOCK" "Block_Name"))))
Can I also determine if there are visibility parameters in the block WITHOUT INSERT the block into the drawing?
Thanks in advance to all who respond.
Solved! Go to Solution.