Hiding RVT links

Hi all, I’m pulling together a load of quick little scripts to throw into a custom extension for my users to quickly turn off all the annoying Visibility/Graphics issues (Reference planes, scope boxes, survey points etc).
However, when I try to use the same approach to create a script that turns off all RVT links, it behaves odd. Rather than toggling the visibility checkbox in V/G, it hides the links as it would if you were to right click > Hide in View. The V/G checkboxes are still checked, but the links are hidden. You can imagine the issues this would cause!

Could someone please take a look at my script and perhaps suggest a better approach?
Note that this does work with other categories, such as Survey Point and Grids, in as much as it toggles the V/G checkbox.

Where do you see a VG checkbox for links? Note that the links tab is inaccessible via the API and as such can’t be manually toggled.

A better solution here is likely to close / open the workset which the link is on (assuming you follow the best practice of one workset per link, one link per workset).

Hi you could also try to create a filter

1 Like

I’m referring to the Revit Links tab within V/G?


I didn’t realise that this was inaccessible, that may explain my issue!
I will look into the Workset solution as that would work better, providing I can be a good BIM co-ordinator and get all my studios to work to best practice!
Thanks

It’s also possible to automate moving the links onto new worksets, where the workset name is created by putting X_ in front of the link name… users might mis-behave, but you can help them get back on track by building such tools. :slight_smile:

2 Likes

Hi @dan.buckingham,

For links, don’t hide the categoy.
Instead, hide the RevitLinkTypes with a hide element node.
You found one of the many peculiarities of the Revit API.

3 Likes

Thanks @Alban_de_Chasteigner, apologies I’m still quite new to my Dynamo journey, how would I go about changing my script to allow for this?
I’m guessing I can’t use the View.SetCategoryOverrides node to handle elements, but I can’t see a native Hide Elements Node. Do I need a certain package, or am I searching for the wrong thing?

You can use the Genius Loci or archilab package :
hide element

1 Like

@sovitek This would be very useful for me. But can you tell me why the error occurred?

You need to feed a document into the proceeding node - the red line on the input indicates it is missing an input and doesn’t have a default value to use instead.

1 Like