Automatic doors in revit with dynamo from dwg



Good morning everyone, I would like to ask the more experts if in your opinion there is a possibility of automatically creating doors in Revit by creating a script in Dynamo that detects the exact positioning of the same from a dwg file. thanks to a member of the group he has already given me the possibility of creating automatic doors in vediante dynamo. I wanted to know if there was any solution to ensure that the distance of the doors is obtained from the dwg file. thank you and thank you very much again to the person who gave me the first solution. I’ll post in the photo the solution I was given and what I would like to try to achieve so that everyone can take inspiration from it and perhaps give me some indications.

1 Like

Hello @Jack22

if you have a dwg you can share then we can try :wink: but when we work in DWG in revit many things can go wrong but not impossible…:wink:

1 Like

Maybe look into using the arcs per block geometry to determine single, double etc. You can then use the arc to also determine rough door size. Project back the centre of the arc by arc radius at normal to the inside of the curve and you find arc centre, connect those points for double to get the placement line, or for single you can connect that point back to the arc with less points in the block curves near it. Assuming your doors are predictable sizes you can get the nearest logical total width from there. Height wont be possible unless your block name implies height though given CAD is plan only.

The doors will have to be blocks for that to work of course. Genius Loci package has a great node for getting block positions but I believe getting block geometry is harder and might need COM API - the LinkDWG package can help there but it’s quite complex.

3 Likes

Could you kindly tell me where I can find this Genius Loci package?
my idea is to choose the door type from the family types drop-down menu in dynamo and ensure that they are generated in revit based on the position of the dwg. it would be great if it could distinguish the dimensions of the door, but I could already be happy if the revit doors were generated from the dwg plan
thank you all

Search on package manager.

1 Like

Hi it isnt so simple you will need sort a lot (depends on how the cad is draw) but you will need create the wall first so your doors have a host…here is a very rough example…

Revit_y94gB7J7ri

9 Likes

wow, spectacular. it is truly an exceptional achievement.

Beautiful, but I think drawing walls in AutoCAD is a mistake and it should be like this. If it was like this, it would not work to use this in drawing walls.
IMG_٢٠٢٤٠٢٢٩_٢٠٢٢١٩


wall223.dyn (112.4 KB)

yeah i just try solve the users problem, with the users sample file…how we should draw i dont know i dont use it so much, but i know it can be a probelem i revit :wink:

1 Like

I was speechless at the work you did. wow, a result without words. congratulations and thanks for the advice

1 Like

Your work and solutions are very beautiful. Thank you for helping us

1 Like

yea cad to revit is an impossibility but we have a script or 2 that does close. i used the arcs to find the insertion point and radius for the size. then i used the intersecting line to the arc to identify the swing side.

for R22
Walls_from_CADv4.dyn (404.2 KB)

1 Like

I wanted to ask when I run this test script I get an error at the “BoundingBox.ByGeometry” node (Bounding box cannot be created because no geometries were provided, why do you think?
Good morning, first of all thank you all for your availability.

When I launch the script I am able to select the dwg, but I am not able to select the door layers and the wall layers from the drop-down menu :pensive:

where can I find the [&]PolyCurve.ByCurves and [&]PolyCurve.ClosedLoopsFromCurves nodes?
Thank you

these are from ampersand, one of the oldest package there still work[ almost all written in designscript] some of my favorite :wink: :wink: I can send you the graph later today…so you can play around with it

I would be immensely grateful

1 Like

Yeps here with respect of swing and hingeside as well, run it a plan view, as i use symbolic lines for that in this case here
Revit_NcPhMRqD64
c1adtest.dyn (193.2 KB)

1 Like

just load it into dynamo and run it?

yes thats the plan, but you probably need to select a walltype in dropdown and a doortype as well, and select the link…i have only tried on that link you shared…here i have just updated so it sort for doubledoor as well…give it a try and play around with it :wink: :wink:

Revit_ktduIInh9u
CAD TO RVT.dyn (210.6 KB)

3 Likes