Having a bit of trouble finding this one - scriptwise, how does one change the layer of a block definition (not an instance)? I don’t see any reference to the layer on which a definition resides in the InstanceDefinition Class. But it does indeed reside on a layer, as if you want to delete a layer which has a block definition on it, you get a warning message.
The idea being that a definition might reside on a layer which is otherwise empty, but it has instances on other layers. If you want to purge the layer on which the definition is, you lose the blocks on the other layers. So I would like to transfer the block definition to a layer that will not be deleted…
Hmm, learning new stuff all the time. Apparently a block definition does not exist on just one layer… It is linked to all the layers that the original objects had. This is easily tested, make a block with objects on a couple of different layers, then copy some instances to some other layers and delete the originals. Then try to delete any layer one of the original block objects were on. You will get the message that you can’t.
So I guess I just answered my own question. There’s no way to do this actually.