Since I have been doing a lot more documentation work in Revit these days, I have become significantly more interested in how Dynamo can automate certain documentation tasks. One task that can always drive me crazy (especially in Revit) is renumbering viewports on sheets.
There are several different ways you can renumber viewports. I decided to use a simple ‘pick’ method so I wouldn’t have to do any reordering in Dynamo. This method works well with a smaller number of views, though it might be worth using a slightly more complex method if you have sheets full of details that need to be renumbered.
If you’re interested in that, I would check out Nate Holland’s AU2015 presentation (Practical Design Computation) and additional class material (with .dyn files). He demonstrates a method where he renumbers views based on a letter/number grid. Since the AU presentation wasn’t recorded, he also posted a screencast video.
But when I was trying to get this simpler method to work, I was having some issues setting the Detail Number parameter. The standard Dynamo node, Element.SetParameterByName, was producing very unreliable results when I tried to set the Detail Number.
Even with a fairly small set of views, the node would fail with at least one of the viewports. So after searching around, I took a look at Nate’s example and found that he was using Archi-lab’s BuiltIn Parameter nodes. These nodes are critical to making this definition work.
This definition also uses several nodes from Clockwork and Spring Nodes. Here it is:
The first node, Springs.SelectElements(ordered), allows you to pick the viewports in the order that you want them to be re-numbered. The Rhythm package also has a similar node with a slightly more Revit-y interface.
Because Revit does not allow two viewports to have the same Detail Number, the definition also requires a two-step process. First, you have to set the Detail Numbers to a temporary/placeholder character. I used letter characters to do this. Then set the final Detail Numbers.
It is very quick and quite satisfying to see it work. Here is the result in the basic sample project:
Awesome!
Where is the PassThrough Node located? Can’t seem to find it in the Clockwork package. Thank you!
Not sure if Passthrough is necessary (I didn’t test it without), but you need to have Clockwork version 1.0.1 or newer.
Where can we find Archi-lab’s BuiltIn Parameter node? Im having trouble locating it.
Thanks.
Archi-lab, Clockwork, and Spring Nodes are all packages with their own custom nodes. You can install them in Dynamo by going to Packages, Search for a Package… Archi-lab shows up as ‘archi-lab.net’. The two archi-lab nodes are ‘Get Built In Parameter’ and ‘Set BuiltIn Parameter’.
Hi, I’m just starting to use Dynamo functionality within Revit, and this post was an extremely helpful introduction to some of the ways Dynamo thinks. Also cures a very annoying Revit task. Thanks!