most efficient way to hide multiple part feature sketches

In an assembly, if I:

View > Hide Show > Sketches (on)

…and there a bunch of part feature sketched in the “show” state, I’ll see them (as I should).

What is the most efficient way to set ALL of the seen part feature sketches to “hide”?

To be clear, this is at the part level, as seen from the assembly level.

Thanks.

Try the macro from here:

https://forum.cadmunity.com/t/hide-planes-sketch-in-assembly/1174/19

It works on parts and assemblies to hide all chosen items.

I was struggling with that today. You can pick the sketches one at a time, but it is not possible to select multiple sketches using a box or lasso.

Yea, it’s a real drag. A time consumer, too.

Try this macro: https://www.codestack.net/solidworks-api/document/sketch/hide-all-sketches/ it hides or shows all sketches (including components if in the assembly)

Does this macro support SW2022.
While in assembly, it almost does nothing. While in a part, it’s a matter of 50-50. Some sketches get hidden, some doesn’t.
Have you tested it on a sheet metal assembly?

Thank you.

Thanks for the macro / API suggestions. I’m not up-to-speed on API yet. Sounds like a good reason to dive into it.

Without a macro, here is how I do it:

select top level and hit CTRL T (this will show tree in flat tree view)
Select top level and hit * (this will ensure that all hole wizard sketches are expanded as well)
Hit F8 (This will show the display pane)
Then walk down the “hide” column and click on each sketch that is not hidden. Should only take a couple of minutes no matter how big your tree is.
image.png
Once you are done:
Hit CTRL T (this will bring you back out of flat tree view)
Select the top level and hit SHIFT C (This will collapse the tree back to its smallest)

Works pretty well.

Thanks, dpihlaja.

The macro suggestions are all great and I’ll look into them long term, but I like this workflow for now. Very helpful.