Hi, is there a way to hide and show objects by name ?
This is instead of hiding and showing the layers.
Mike.
Hi @Mike_A
You can either run Hide
/Show
followed by SelName
- or run SelName
followed Hide
/Show
. Note that if you rund the dash-version of SelName (-SelName) you can also script the name(s) to select.
HTH, Jakob
Hi Thanks,
But… when I combine those commands into a button, it reveals everything, then gives a me a selection choice.
my Button Commands -
Show SelName
What should I have ?
Regards,
Mike.
did you have a look at
https://wiki.mcneel.com/rhino/basicmacros
if you name one object “test” and another “test 2”
-_selname test
-_selname “test 2”
-_selname test*
(1) will select the first,
(2) the second (showing how to use white-spaces, but i would recommend to avoid…)
(3) will select both using wildcard * placeholder
make sure to use "..."
(straight quotation marks)
not “…” open / closing ones.
@pascal at the mac macro-Editor quotation marks do not work, i have to paste them from a text-Editor, and as soon as i change the macro-Text, they change to open /closing ones, and the macro will fail
@Normand any example for a scripted name ? is regex supported ? or what do you mean by scripting beyond wildcard ?
Hi Tom,
I have made many other buttons that work fine, what I need is a bit different to your approach of putting the object names in the script.
I have several hidden named objects in my scene, I want to be able to press a button that brings up the list, then I select a name from the list, and it reveals only that object.
Mike
sounds like you need a script.
a starting point might be this:
instead of selecting the objects use
https://developer.rhino3d.com/5/api/rhinoscript/object_methods/showobjects.htm
kind regards -tom
Hi @Mike_A
Combining ShowSelected Selname
should do that, I think
-Jakob
_SetRedrawOff
_ShowSelected
_SelName
_Enter
_SetRedrawON
Hi Jarek,
Thank you, that works very well !
Regards,
Mike
_SetRedrawOff
_ShowSelected
_SelName
_Enter
_SetRedrawON