Setting calculated value, from elements, to Parameter within family

Hi all,
Our current project has custom “megapanels” that are composed of operable, fixed, friteed, and it’s framing.

These were imported from autocad and have their own layers.

Since I need to do area take offs i decided to use dynamo to select all instances of a type(i.e. all operable windows) and calculate a total. I would then put the total manually into parameter i created for it.

I want to bypass typing it in manually and just have dynamo write the calculated value to the parameter within the family.

I’m having a hard time figuring out what the right way to do the last part is.

Please see below.

I also moved the sum directly to the parameter.SetValue. The paramter GL1 i had already created within the family.

Here are the parameters within the family

I don’t know if understood it correctly, but why not use a a formula for the totals?
So Parameter 1 + Parameter 2 + P… etc. as formula for your totals Parameter (GL1?)

For Dynamo. Where do you wanna write the value to (in other words; what element has the total value parameter? Start looking at Element.SetParameterValue.

Thanks for the reply!
I’m actually combing the surface area from multiple elements. That is what the original script is calculating.
It calculates all selected elements below(the ones with red check marks)

I get the calculated total and I want to write that into an already existing parameter such as GL1.

So each panel got the Parameter GL1?
Anyways; you still probably need the node

NB I am pretty sure :slightly_smiling_face:.

Ha no parameter exists within each element it only exists in the family. This is a mega panel. When loaded into the project it sits within a curtain wall. Below is the full panel before being loaded into the model.

We had to go this route because each megalpanel is sloped in two axes. So we made megapanels within a single curtain panel family.

Aah, so you ran the .dyn while in the Family editor(?).


ha is this a faux pas?

I’m getting the calculated value but i don’t know how to assign that to a parameter.

But when you load it into your project doesn’t it already give you a total area (build in Parameter)?

I am on mobile, so i struggle a bit helping properly.

I get the calculated value. I then manually type in the value in the family parameters.

I appreciate the help! Especially if your mobile, impressive!

So want the area of each panel written to a Parameter? I.e. 5 different panels to 5 different Parameters?

Well say i have a number, regardless of how it’s obtained. Do you know how i add that to the family parameter without leaving the family editor?

I never done that. Never needed it. So no.

Maybe this helps?

Or maybe the Math.Sum should be converted to Strings first?

1 Like

According to this your .dyn should have

Did you start Dynamo when within the Family Editor?