Scripting layer change

Hi,

Can changing layers be scripted based on a current selection, using common layer names.

Ie:

  1. Manual selection of objects
  2. Click macro / shift selection of objects to desired named layer

Input appreciated.

Will.

Yes.
For example, the macro -ChangeLayer curves will move the selected objects to the layer called “curves”.

2 Likes

thanks, ill give it a shot.

Thanks for tip, the layer is called ‘Drafting Line’ it doesnt seem to act on two word labels? also, some of my layers are nested in sub layers, this doesn’t seem to work, any clues how to make this work? Thanks.

To allow spaces in passed strings/names you should pass them encapsulated in double quotes:

-ChangeLayer "curves with space"

Does that Help?

-Willem

1 Like

SubLayer syntax is as follows:

Layer::sublayer::sublayer…etc.

So:

-_ChangeLayer _Pause "Top Layer::Next Layer::Bottom Layer"

–Mitch

1 Like

Thanks, ill give it a crack asap. Cheers for that.