How to place a view in the center of a sheet

Hey All,

I am looking for a way to place a View in the center of a sheet with Dynamo. I have an add-in that creates sheets from Scope boxes, creates views from those scope boxes and then places the views it creates in those sheets. I am struggling to find a way to center those views in those sheets though. I have found a couple posts on issues similar to this but none of those resolutions seem to have worked. Any feedback on this would be greatly appreciated.

What have you tried so far? Where are you getting stuck?

1 Like

This is what I am trying currently. I have also tried the solution proposed at this link ( to no avail. My current attempt appears to be doing nothing. I was attempting to find the center of the sheet and then move the view to the center of the sheet but I appear to be missing something.

Can you show the node previews? We can’t tell what’s happening if we can’t see. Does the SheetView actually return a bounding box?

Interestingly enough, ViewSheets do return a bounding box, although it will always have a min of (-100, -100, -1000) and a max of (100, 100, -0.1) regardless of the titleblock size, as far as I can tell from my limited testing.

I think you are hitting on the point though that you don’t want the centroid of the viewsheet’s BoundingBox, but probably rather the centroid of the titleblock’s.

If I recall correctly, the node you’re using to place sheet + view will drop the bottom left extents of both elements at the 0,0,0 point. In a relocate workflow you’ll want the centroid of the viewport as well as the centroid of the workable paperspace from the titleblock family to get that centered look.

Our inhouse workflow for this is pretty sloppy:

What tripped us up that we never doubled back to address (as you can guess from the screenshot above) is how to compensate for offsets due to the size of the actual titleblock on the sheet, since we pull in the main consultant’s titleblock family.

If you’re using your own titleblocks this might be as simple as a dictionary based on your standard printing sizes.

Exactly what I was getting at. You would get the bounding box of the titleblock, find its center, and then locate the view at the center of the TB rather than the sheet. It does mean that you have to be extra careful not to have anything (text boxes) extending beyond the limits of your TB.

Is there an easy way to find the center of a title block? I am struggling to find a way to do that.

Again, what have you tried? Do you have the TB of the sheet? That’s the first step. Once you have the TB you can get the center from the bounding box, most likely using the min and max points.

This is what I am trying currently.

This is what I get. It’s weird. It seems like it centers the title of the scope box/view at the bottom but the actual view seems to not get centered.

You’ll need to get the boundingbox of the specific TB on the sheet. Sheets have coordinates just like any other view, so it’s possible for a TB to not be located at the view’s origin.

I honestly forget if views get placed at their center or bottom-left corner. If you don’t have Revit Previews turned on it’s probably a good check for your coordinates. Make sure the min and max point of your boundingbox matches the bounds of your TB. Also try placing a view at (0,0) to see if it’s centered or offset to the corner. Then you’ll know if you have to account for centering or not.

When I place the view at 0,0 it sticks it here. It seems I will need to adjust the center point that I was using to account for this.

I think I got it. This appears to be working.

Viewports get placed by their center. I use Viewport.Create from the Rhythm package, then I use Element.MoveByVector to move it to the center. this works more reliably in my experience when doing a lot of sheets at the same time.