Get all views with a certain View Template


#1

I am trying to look at all views in my project, and filter out all the views with a specific View Template applied. I have specifically grabbed all 3D views, and tried to run it through a View.IsViewTemplate, but I don’t know what the next step is, or how to filter out using bool if it is a specific Template. Can anyone point me in the right direction?


#2

Use the node FilterByBoolMask, plug the 3d views into the list and the View.isViewtemplate to the mask, you’ll get the result you need


#3

Like this:

So the custom nodes are from Archi-lab.net package.

The idea is that you:

  • get all views
  • isolate only views that have view templates. Since we selected ALL views that includes weird things like project browser view, and actual view templates themselves etc. By doing this step we exclude all views that can’t have a view template applied or simply don’t have it.
  • then we filter out the views that do have a view template by comparing it against the view template that we want to extract.

Good luck!


#4

Thanks guys, I got it working.