Is there any Way to turn off newly created layer in All layout and Detail

Sometimes we create some layers which we dont want to include in the previously created layouts, it is ok to manually turn off layers if we have 4-5 detail views only but for more than 15-20,we need some automated way to that. maybe there is some way to do in rhino but i have created pythonscript using chatgpt but it is unable to solve the error, can anyone correct the code to turn off all layers in detail layout

  1. Is there any way in Rhino to select layers in layer panel by selecting objects in viewport.
    So we can quickly change the properties of those layers in Detailed layouts.

Does this work for you?

HideLayersInAllDetails.py (2.7 KB)

I haven’t tested it in the WIP, there the model/layout visibility controls have changed and I’m not sure it works anymore.

This works like charm,
is there any way to turn on specific layer in all viewport.

Also, i think that the default behaviour of detail view should be to turn off newly created layer and if the created layer is sub-layer then its visibility should be based on parent layer.

Can you suggest some resources to learn python from scratch to advanced level for rhino.

Yep.
ShowLayersInAllDetails.py (2.7 KB)

I guess start from here:

The Primer is a good course to go through.

After that it’s just practice, practice, practice - and ask questions here.

1 Like