One Layer On by selected object?

Having to scroll through the list of layers using the typical OneLayerOn command always seems to interrupt my workflow. I’d love to be able to select an object, type a hotkey/click in my popup menu, and have all layers other than the one that object is on be turned off. Is there a command or macro that would accomplish this?


_-OneLayerOn _SelectObject

works, but not on preselected objects…

Otherwise I guess a script…

This actually works beautifully, so thanks! However I should have said this in my initial post, but it would be nice to be able to select multiple objects on different layers. Having the option to pre-select objects would also be very useful.

Really what I’m hoping for is a Rhino version of Autocad’s LAYISO command.

You can try this one out, not sure if it will work reliably with sublayers though (as parent layers also need to be on). It seems to work OK in a couple of quick tests here.

If you choose objects that are not on the current layer, the current layer will be changed to the layer of the first selected object.

Let me know if it errors out somewhere… (736 Bytes)

This is PERFECT! Thank you so much for taking the time to make that. I know a little Python but absolutely nothing about scripting for Rhino so I could never have done this on my own.

I went ahead and made an Alias that runs this when I enter “LI”, just like Autocad.

I could use this one as well…Thanks for asking Jaddi and thank you to Mitch for writing it.


Works great Mitch…I just added it to the “one layer on” button as a right click option.