Hello - I am new to Dynamo and I am running into difficulties with my first script. I am trying to renumber rooms that were place out of order using a spline and I’ve found many different YouTube and written tutorials, all of which don’t quite seem to work for me.
When I select the spline and run the script the room number sequence for the whole view updates, not just the spline selected rooms, and I think they’re following the order of the element ID rather than starting at the spline start point and counting up each room to the last control point.
I’m also encountering an error that may or may not be related to the issue that occurs when I pull the room poly curves onto a flat plane. The error says the poly curves are self-intersecting and I think this may be related to the use of room separation lines and columns which run through rooms, but I haven’t found a way around this.
I’ve tried all of the recommendations on that thread previously and nothing has changed. When I run the script the room numbers do change, but they change out of order. For example, instead of the room number sequence starting from 1 and then increasing in count to 2,3,4,5 etc., it starts at 9 and increases in count to 10, 11, 14, 22, 21 etc.
By the looks of it your List structure / filtering isn’t right.
When i test it in a project with 9 Rooms and the Spline goes through
only 4 of them i still get 9 Rooms. Also i think you don’t need List.Reverse.