Placing dimensions from an air terminal in a space to the closest separation line or space boundary

Hello, I’m trying to make a script to automatically place dimensions between an air terminal in a space to the nearest separation line or space boundary (in X and Y direction).

I have a problem with placing lines from the air-terminal to the nearest separation line.

The biggest issue is that I don’t know where to find the reference of the “separation lines” or “space boundaries” to connect to a dimension-node.

Many thanks in advance for your feedback

Hello @johanQZGZ7 and welcome, you could try with genius loci dimension nodes, and get your reference from airterminal, with family_origin_reference node, and for separation line, you could use element reference node, and the line for placement, you could try Geometry.ClosestPointTo and create a line from these points, and pull it on viewplane, thats could be a start…here is one example

Thank you very much :slight_smile: for your feedback and getting me a few steps closer to the solution!

I am wondering how to do the following.

I made a list of all the spaces in the model and also a list of all the air terminals in these spaces.

The goal is to find the nearest space-center-boundaries in the X and Y direction (of the space this air terminal is located in) and create a dimension between these boundaries and the air terminal.

Created several scripts but they don’t work.

Also, when the dimension by reference node gives an error about connecting a floorplanview instead of a view.

Many thanks in advance for the reply

not sure its possible get reference from space bounderies, but you could get it from the walls both linked or not.. from bounderies only if you use separationsline as basic is i a modelcurve,