Hide Lines in View by LineStyle

I’m trying to create a script that will hide all lines in a project with a certain name. I was following this post, but I can’t seem to get the same results. I can filter our my lines correctly, I just can’t seem to hide them. I seem to be getting string errors. Does anyone have any idea how to fix this?

Try setting the lacing on the View.HideElements node to Longest, and set the List@Level of input “Element” to L3. That might do the trick.

image

That seemed to give me more errors

image

Try flattening your list of lines.

3 Likes

That did it! It was that simple. Thanks guys

Setting your ListLevel to 3 is the same as leaving the list as it is. Level 3 is the outer most list, which is what the node would be looking at by default. You could just set the ListLevel to 1 and leave the lacing shortest. That should also work.

1 Like

Interesting, I guess I thought of that backwards then. I always thought L3 was the innermost level. Thanks!

It does seem a little backwards at first, but it actually makes sense when you start using really deep lists. If you look at a node preview it actually tells you the list levels at the bottom. Each level lines up with the indent of its list/item.

2 Likes