Copy Sheets: Adventures in drawing numbering

Hi all - I’m new to pyRevit, and am curious to know if anyone has experienced this issue:

  • Revit 2024.3
  • Workshared Model File, BIM 360
  • “Copy Sheets to Open Documents”
    I’ve set up a ‘general details’ catalog file with drafting views of common details arranged & numbered on sheet layouts. Our goal is to utilize the ‘copy sheets’ feature to create import these ‘sheeted & numbered’ details to multiple building model files that will reference these details, via callouts in sections, elevations, plans, etc.

The copy function has worked in other past projects, but with our current project, this function seems hellbent on renumbering most of the details on each sheet. The viewports arrive in placed correctly in our 12-square grid (more or less - sometimes they’ve shifted slightly) on their respective sheets, but somehow the drawing numbering has changed; 3, 10, 2, 4, 6…random, no discernable order or logic. No matter what we try (“publish”, close out, restart, etc.), the result is exactly the same. We’ve been manually re-numbering them.

It seems that pyRevit might be relying on some kind of cache here, and it’s overriding the most recent drawing updates. Any theories or proposed fixes would be greatly appreciated.

Travis

Hi @wtravisl,

I’m a bit of a noob so this might sound silly, but could you not renumber the details via the script you’re using to place them? As in, do everything you’re currently doing, then iterate through all your sheets and then renumber the details on them, based on whatever logic you want?

This is a little bit of extra work, and it assumes that you want to number the details based on their positions on the sheet or some other calculable property, but it’s certainly the way I would go about handling this problem.

Let me know if any of that is unclear.

Benjamin

Hi Benjamin,
Thank you for your response. I understand what you’re proposing, but it sounds like a marginal improvement at best. It still represents extra time & potential for human error. The pyRevit “Sheets/Copy Sheets to Open Documents” command should get the numbering correct automatically, by default, without any manual workarounds - it’s obvious that something about our setup is throwing it for a loop, and it is generating sheet numbers from a bad info source. I need to keep poking around until I figure out what it is. It’s happening again, right now, with a completely different project to the one that generated my initial comment.

1 Like

Here’s the code for that function:
GItGub pyRevit,

I’m not seeing any reference io the code for sheet numbering - either applying or setting numbers. It doesn’t look like this function intends to deal with numbering.

Are you just copying views? Not the triblock? If so your position issue is probably an issue of the titleblocks in each view differing in placement. Users have a tendency to bump these or move them by accident when they move some other sheet element. Always reference the XYZ(0,0, 0) to the lower left corner for best practice. Sometimes people even change the lower left sheet corner in the wrong spot in the titleblock family. Very poor practice when editing titleblocks.

As for the numbering… Are there any error in the logger?

Are you using the same version of Revit as with past successful projects? More information would be needed to assist.