Blocks Collection (ActiveX)

The collection of all blocks in the drawing.

Supported Platforms: Windows only

Class Information

Class Name

AcadBlocks

Object Inheritance
Object
   AcadObject
      AcadBlocks
Create Using

VBA

Not applicable
Access Via

VBA

Document.Blocks

Members

These members are part of this object:

Remarks

To add a new member to the collection, use the Add method. To select a specific block, use the Item method.

There are two special blocks in the collection. One contains the collection of all model space entities, the ModelSpace collection; the other contains all paper space entities, the PaperSpace collection.

Although the Blocks collection inherits a Delete method, you cannot actually delete the collection. Attempting to delete the Blocks collection will result in an error, therefore the Delete method has been removed from the documentation for this collection.

There is no limit to the number of blocks you can create in your drawing. However, there can be only one instance of the Blocks collection. The Blocks collection is predefined for each drawing. You can make multiple references to it by using the Blocks property. Once done with an object, the reference is automatically released.