Renumbering Views based on Grid

Hopefully this is in the right spot, but I came across a post that tied together an external Python script inside of Dynamo that allowed you to update the Detail Number based on a user defined grid layout and by specifying some boundary on the title block. Malcs tools - Archigoodies for dreamers and lazy people. - Renumber Views on a sheet though it doesn’t seem to be updated/revised in a few years.

I took the suggested route of embedding the values (grid & boundary) inside of my titleblock file but i doesn’t seem to work. As I move the view around the sheet it seems like it’s picking the grid at random. Each grid is 1.5"x1.5". Not sure if it has something to do with the detail symbol placement on the lower left rather than the right.

I think you would be better served to just use the geometry of the sheet.

You can see if the graph I made a couple years back works for you. You will need to adjust the “Bay” spacing to fit yours at 1.5", and the other filtering information, but seems like it should get you very close.

ReNumber Views.dyn (55.5 KB)

Hmm. This could work. Might have to find a way to eliminate letters I & O.

After playing with it a little it appears that there’s no real boundary, right? Even if the view is placed beyond the border it’ll assign a Detail number (I’m okay with this - Just want to make sure I’m seeing it right). My worry though is if someone was to move the border running this script could give what appears to be random numbering

Also, might be a dumb question, but where is the starting point/origin?

You could create a list with the letters you want and then use GetItemAtIndex to skip some.

Yes, it will number any view on or off the sheet.

It starts bottom left of the sheet, not title block, so yes it could move.

Just now getting back into this. I’ve gotten everything set up properly… Apparently I didn’t have my border outline placed at 0,0 so it was throwing some things off.

For skipping letters, I’m assuming I’d need List.GetItemAtIndex, List Create & a code block with all the letters I’d want to use, right? I’m just drawing a blank where that’d get fed into

1 Like

You could skip the List.Create and just use the code block output.


Ah, after some messing around I was able to get it to work. Thank you so much

1 Like

Glad to hear you got it up and running. Could you post the working graph for reference to others?

Graph attached… Might do some more tweaking, but for now I’m happy it works.

1 Like

Noob here… Whenever I try running the script, I get these errors…

It is because you are using nodes that are old or cannot be found.

  1. Remove the “RDG” node for sure.
  2. Update Packages