Auto-Dimension from Walls

eu testei essa rotina na funciona comigo assim, e sem aviso. porque sera? estou precisando de rotina pra cotar as paredes.

Hej,
work only at lowest level, why?

Good morning @Mark.Ackerley

Has there been any development for your Auto-Dimension script in the updated Revit 2022 API?

See attached screen shot.

I’m using Revit 2022 and Dynamo 2.10.1

Many thanks.

Hello everyone, here is my attempt for a script that will dimension entire walls from the core faces and openings. What I will be using it for is for construction documents were you need the dimensions from the core faces of the walls (wooden stud walls) and the opening widths. The problems that I was not able to solve is when we have an inclined wall like in the attached image as I cant get a reference at the joint of the two walls. Its made only using nodes as I am not very familiar with Python so maybe it can be optimized quite a bit. Also it sometimes does crash Revit for some reason which I can’t yet figure out. Any help would be appreciated. I do think this will save a lot of time for many people and it can be modified to take the wall exterior and interior faces as well when the thickness of the structure is not required.

The used packages are Genius Loci Clockwork and ArchiLabs
Dynamo is 2.10 and Revit 2022

Thanks!

autodim.dyn (279.7 KB)

Heya,

Yes, it is a doozy isn’t it! :slight_smile:

So it looks like you are trying to dimension wall cores? And your graph uses perpendicular references, which isn’t going to work for inclined walls…

My solution was based on edge (references) of the wall geometry, so it could pick up the vertical edge (reference). But I think you will struggle, because the wall solid won’t have a vertical edge (reference) for the wall core… If I tab in Revit, I can pick the vertical edge reference as a dot for the external and internal faces, but I can’t for the core.

The only workaround I can think of would be to place lines at the points where you would like the dimension, though obviously this would not update with the walls.

Hope that is of interest,

Mark

Thanks @Mark.Ackerley I will look into it. What concerns me more is why it crashes Revit sometimes. Maybe its something to do with the custom nodes or some data it can not parse? I couldn’t really identify the issue but it happens on bigger models with lots of different window and door families (all have their references named etc. so the script could catch them). I would be really grateful if someone can check if he has the same issue and can pinpoint the source.
**What I did find is that the graph runs fine if the output nodes (Dimension byReferences) are frozen. So it makes me think there is some issue when it tries to print out the dimensions into Revit.

Thanks,
Plamen

No worries, if it’s just affecting bigger models, perhaps it is a RAM issue? Otherwise, it might be some oddity which is rare and turns up in only those bigger models… Quite a slow task to isolate unfortunately.

I would see whether it runs if you just create 50 dimensions? Keeping an eye on your Task Manager?

Maybe if that is the case, you could run a graph to dimension just the window openings, say, with a 2nd graph/setting to do walls etc. You’d need to adjust your graph to dimension pairs of references instead of a whole run.

If you can isolate an oddity which is the cause, we can look at that for a solution :slight_smile:

Let us know either way,

Best of luck!

Mark

I am getting the same message ,
Do I need to download specific packages ?

I am getting the same message like reecethorner92 , is there anyway around ? Do I need specific library or packages to download ?

DisplayUnitType property has been removed from API 2022, it is recommended to replace it with GetUnitTypeId Method

Sorry , I am not that expert , should it be like this ?


where cPlaneHiMM = UnitUtils.ConvertFromInternalUnits(cPlaneH, GetUnitTypeId.DUT_MILLIMETERS). ?

try this

UnitUtils.ConvertFromInternalUnits(cPlaneH, UnitTypeId.Millimeters)

did that and said maybe also in line 78 I need to change DUT_MILLIMETTERS

, I a

but I still see the issue , I appreciate any kind of help regarding this

you should replace all

DisplayUnitType.DUT_MILLIMETERS

with

UnitTypeId.Millimeters

1 Like

Thanks , it worked as attached but the sloped wall is giving null result for measurements , is there anyway I can measure the sloped wall and if I want to measure in feet and fraction inches , what I should write so it reflects ?

I have to either exit from dynamo and restart to make running the script is effective for each operation , is there anyway if I run it manual then I do not have to restart dynamo ?

Thanks , it worked as attached but the sloped wall is giving null result for measurements , is there anyway I can measure the sloped wall and if I want to measure in feet and fraction inches , what I should write so it reflects ?
Screen Shot 2021-11-14 at 9.26.24 AM
Screen Shot 2021-11-14 at 9.26.24 AM
1920×1171 152 KB
I have to either exit from dynamo and restart to make running the script is effective for each operation , is there anyway if I run it manual then I do not have to restart dynamo ?

Hate to ask @shehab10, but any chance I can beg you to post your .dyn file? I have a student with a very similar issue and have been trying to help her figure it out. I downloaded the latest .dyn that was posted in this discussion, but it still crashes when she (and I) try to run it.

I’m very curious to see exactly where you made changes that solved the issue.

Hey @ttunate, check if you have downloaded Marks script and not mine, as mine does crash and I still have not found the reason behind this.

Thanks @P.Tod, I went back and found the script you mentioned from @Mark.Ackerley. Was able to run it successfully* but have one more question for you that I think may be a rookie mistake.

The script runs with no errors, generates a 3D view in Dynamo, but does not populate the Revit plan with dimensions. Any suggestions? It is clearly doing something, but I believe that there is one last piece that I am missing.

When I change this Code Block to 5 it generates lines on the 3D view in Dynamo:
image

But no dimensions carry over to the file:
image

I’ve checked cropped region, and hidden elements, to be sure. This is newbie talk trying to figure this out, but are these lines simply the reference lines for the future (no yet showing) dimensions?

This could be a great tool and I’m grateful for the work you all have put into helping thus far!


Check that the block that generates the dimensions is not frozen. I can’t think of anything else. If its something to do with python scripting I am not able to help.