Renumber details according to spline

Hi, I’ve created a script to renumber details according to a user-drawn spline. It takes the viewports’ centerpoints and sorts the viewport according to the t-parameter of the spline. However when I click run and it starts renumbering the details, I think the details renumbered are re-fed into the definition, and so it causes an error. I’ve tried doing it in two steps: first renumber the details to [_1, _2, _3, …] and then back again into [1, 2, 3, …] but this does not work either. Does anyone know what is causing the error? Note: to run the definition you’ll have to draw a spline. Also, remember to use dynamo in manual run mode. Thanks! Renumber Detail Views Renumber by spline

Hi Jesus,

Which package custom nodes and Dynamo version your using.

Have you been able to get this work work without a spline? I’ve been trying to get Dynamo to simply renumber the sheets from top left to bottom right.

I made this graph to renumber the detail views in the order you select them:

BTW any way of getting viewport coordinates in order to automatically renumber by location?

I answer myself: Viewport.LocationData :slight_smile: