Hi,
I have a linked Autocad File and i would like to “find” doors, wall-lines and connect them in Revit, so that afterwards i could create a room seperator-line with it. I could already “find” the doors (trough arcs), wall-lines and all the points which connects the doors with the wall-lines. My problem is now, that i can’t find out the corresponding line which is connected to the door through the points which connects the door with the wall-line.
In the attachement you see a list with lines (which is corresponding to all the wall-lines which dynamo found in the linked Autocad File) and a list with points (which is corresponding to all the points which connects the doors with the wall-lines)
If your “setup” always has three lines and a curve, one line tangent on the other two lines you just have to make some small calculations to find out which curve is the one which doesn’t have the same direction as the other two.
Assuming all your doors are arcs and have a leaf line going back to the wall line, you can find which line is crossing the door by getting the arc centre as well as start/end point. Make lines between the arc centre and these two points, and we know one of these must be the door leaf line, and the other our door threshold (which has no line). Get all midpoints of lines in the line set, then check if the midpoint of the lines we drew exists in those points as a string. If it doesn’t then we know this line isn’t drawn and must be our threshold line.