Hi,
Why I am getting error at Math.round. I am trying to extract window width and height parameters and bring it to Excel
Try List.Clean → Object.Type → List.UniqueItems and check the output, see if there’s anything strange.
Some of your elements don’t have a parameter value. Those will need to be filtered out before you progress. Preserve indicies to false on the list.clean node should work, but depending on your end goal you might want to filter the elements by testing if the parameter’s value is null.
the thing is some of the revit parameter values are null before assigning it for the first time. like checkbox for example, its null at first though it looks false.
Thanks to all of you. but I still not getting it. Appreciate all the help I can get
2024 revit version_math round error.dyn (20.8 KB)
The values aren’t null, they’re empty. You need to use the condition that @christian.stan suggested of checking for empty string values (data=="";
). The null comes from trying to round an empty string.
Thanks @christian.stan @Nick_Boyts and everyone :), appreciate you all
Just as an FYI, you don’t need to invert the boolean values before you filter. The in
and out
outputs are for true
and false
values respectively. You can just use the out
port instead to get the false matches. In a case where you really do need the not
condition, you could just include it in the original statement: data != "";