Creating Dependent Views From Excel


I am new to Dynamo and this is my first post.

I have used replicated a previous solution mention on this forum to create dependent views from scope boxes by selecting from the dropdown views.

I am hoping to automate this method by using an excel spreadsheet containing the views I would like to duplicate as dependent and apply a scope box. I am not sure what I need to change for the View.DuplicateAsDependent node to work.

All help will be appreciated.




Welcome to the forum.

Are you trying to use the Excel list as the list of views to create duplicates of, or is the Excel list the list of view names that you want to name the duplicated views?

I am assuming you are trying to do the first thing. You are feeding into the View.DuplicateAsDependent strings (text), but what that node is looking for is actual view elements (put a watch node after the “Select Model Element” to see what Revit Elements look like in Dynamo Form…). What you need to do is use the Clockwork node Document.Views to get a list of all the views in the model (a very long list…), then find the name of each of those views, and then use the names in your Excel list to “match” with and pull the particular indices out of the view list to get a list of only the views that you want to duplicate. Then feed that list into a List.Map and use the View.DuplicateAsDependent as the function.


Thank you for your help. Still struggling to get it together. I have used an in house routine to capture the element ids into an excel to use a s filter. Not knowing what every node does it is a bit of a guesswork and the guessing on majority of times wrong . Not even having beginners luck. :frowning:

Is there a description available for the functionality of some of the nodes. I do not know how to use the List.Map node whether I am using it in the right context it is another matter.

What I have so far does not come back with an error but does not do what I hope it to do>