In order to quickly select block references from a DWG drawing and first of all to perform block selections from AutoCAD script files, you may need a useful tool for selection of blocks by their name.
This function can be performed in two simple ways. E.g. if you need to erase all blocks named "MYBLOCK" from your drawing, use one of the following methods (menu-macro format used for readability, for scripts replace the semicolons by spaces):
* _ERASE;(ssget "_X" '((0 . "INSERT")(2 . "MYBLOCK")))
* SSX;;B;MYBLOCK;;_ERASE;_P;;
The first method uses the LISP object selection function. The second method uses the command SSX from Express Tools.
None of these methods can be used in AutoCAD LT.
This function can be performed in two simple ways. E.g. if you need to erase all blocks named "MYBLOCK" from your drawing, use one of the following methods (menu-macro format used for readability, for scripts replace the semicolons by spaces):
* _ERASE;(ssget "_X" '((0 . "INSERT")(2 . "MYBLOCK")))
* SSX;;B;MYBLOCK;;_ERASE;_P;;
The first method uses the LISP object selection function. The second method uses the command SSX from Express Tools.
None of these methods can be used in AutoCAD LT.
No comments:
Post a Comment