Author Topic: Creating a block  (Read 2442 times)

0 Members and 1 Guest are viewing this topic.

iliekater

  • Guest
Creating a block
« on: March 29, 2009, 02:19:58 PM »
I would like to a ask a question about creating blocks with VBA . You see , I don't want to create block of a circle , a text etc , instead I need to create a block that will actually contain everything drawn in the screen . As far as concerning the inserion point , the (0,0,0) point will be fine , but my problem is I don't know how to handle VBA to select objects (in this case all of the objects) .

Jeff_M

  • King Gator
  • Posts: 4096
  • C3D user & customizer
Re: Creating a block
« Reply #1 on: March 29, 2009, 03:12:53 PM »
Use a SelectionSet to get the objects, place those into an Array of objects, use the CopyObjects method to place them in the new bloick definition.


Unless you want ALL modelspace objects in the block, then just loop through the ModelSpace obejcts and place those into the Array to use with CopyObjects.

iliekater

  • Guest
Re: Creating a block
« Reply #2 on: March 29, 2009, 03:58:21 PM »
OK , thanks , I'll give it a try .