I have a script ready to add view filters to view templates. It only works on a single view template. I would like to change this so that a view filter can be added to multiple view templates at once.
However, the node view.addfilter only accepts one view. Does anyone have an idea for this? maybe there is a node in another custom package?
This will be so helpful! For clarity, what are the code blocks referring to in the ‘which filter’ group? I’ve just tried running with the first showing “ParameterFilterElement” and the second as my filter name, but am getting an error. And not sure where the levels should be adjusted…? I appreciate the help!
I thought I had solved this the other day, but it turns out it’s still not quite working. @Joelmick, is there anything to update now for Revit 2021+ where Filters can be both ‘Enabled’ and ‘Visible’? The goal on my side is to 1) add the filter to all plan view templates and 2) turn off the visibility. Your advice is most welcome!
it look like you used the same code blocks. if i use a custom package, you can see in the script wich version i used. mine works fine in revit 2020, mayby newer version its not working? did you get it ready yet?
Thank you, @Reinier – yes, everything seems to be the same, and it doesn’t give me any errors when I run it (just says ‘Run completed’). I think the difference is to do with 2021 and the added need to select both ‘Enable Filter’ and ‘Visibility’ here:
Could this be an override written into a code block? Replacing the overrides node? Just not sure how to both add and affect the ‘visibility’ side of it.