Change Detail Number of Viewport Based on Location on Sheet

Hi, I am looking to change the detail number of a viewport based on its location on a sheet. The template for sheets provides a grid (1-6) on the x-axis and (A-E) on the y-axis. Depending on which space (A1, B1, C2, D6, etc.) the viewport title of a specific view on a sheet lands, I would like the detail number to reflect that space. I know this is possible by setting the parameter, although I am having trouble receiving views and creating the grid that the detail number must follow. Thank you!

Nate holland’s Autodesk University 2015 presentation is a great resource for this.

Practical Design Computation_Files

Unfortunatly that presentation wasn’t recorded. I gave a slightly less polished recap of it at NBBJ a few weeks later that I did record and post on vimeo.

Watch “Practical Design Computation: Dynamo for informed design and streamlined BIM” on Vimeo:

Take a look and let me know how it goes.


Thanks Nate!

Hi Nate,

Thanks for posting the link! I’m following through the steps of creating this script but am getting hung up on a couple nodes.

  1. In your “Get the title block on the sheet” group you have a " - -" node directly after both Element.GetParameterValueByName. You mentioned this as a compare command in the audio but I’m not sure that is what this actually is. Can you clarify this node for me?

  2. There is a custom code block under both the get sheet height and width offset groups that I am having trouble re-creating. This is the code block that includes the x or y, width or height, and conversion factor (for me from feet to inches). Any tips or links on how to go about creating this one?

Thanks in Advance!

Hey Adam,

Sorry for the delayed response, I was out on vacation.

  1. the node is an “==” node which tests if A is equal to B
  2. the code blocks in the get sheet height and width groups says (width+x)*conversion and the conversion code block has the number 304.8 in it
    See the attached handout for a bit higher resolution and written explanations
    handout_12000_Practical Design Computation_Handout.pdf (2.4 MB)
1 Like

Nothing like bringing back a thread 21 months after the last post!

Nate - if you see this, you are a life saver. I knew someone had been teaching a way to solve this issue for some time, but I’m only just recently finding the time to learn Dynamo. I had to make some tweaks in order to get the graph to work with my company title block, and i had a question and a comment.

Question: Does this proccess need to happen on a sheet by sheet basis, or can the graph be redesigned to renumber all views on all sheets throughout a project? If so, is there a reason NOT to?

Comment: I found I needed to subtract the left margin and bottom margin dimensions (in feet) from the viewports’ X & Y point locations prior to dividing them by the corresponding cell width/heights. Without adding this step, i was running into errors with views placed near the far edges, and dynamo the cell divisions were not accurately lining up with the drawn locations on the titleblock. The fact that we have 11 horizontal cells, and 9 vertical cells (compared to your example’s 5/6) may have exacerbated the issue.