Values from excel into revit change

revit
excel
dynamo

#1

I created a program to put values from excel into Revit. This all works fine for lengths but when it comes to mechanical flow and thermal conductivity the values actually change.
14 changes to 396.44 L/s and 15 changes to 45720 W/(m*K).
Why does this happen?
Is there something going with the specific units of measurement? How would I circument this?
All values go through the exact same process so the issue doesn’t lie there.


#2

have you tried to import them as String?


#3

I have now, but the Element.SetParameterByName node doesn’t accept that as value.


#4

use String.ToNumber node after importing your value, to convert the back to integer


#5

It functions now as it used to. So still with the wrong value.

I also don’t understand why it would work otherwise.


#6

can you post screen shot for your script and result ?


#7

This is what’s in the excel file, you might notice I’ve chosen the values for testing reasons (and that I’m Dutch):
image
This is wat eventually goes into the node:


And this is the result (Edit: for Type 1):
image
I don’t think there’s much of a question where it goes wrong, I am wondering why and how I could circumvent it (hopefully not by just adding an extra calculation to change it back in some way).


#8

aha , that’s related to parameter type of Waterstrom & Warmtegeleiding and their units

you can do that experimental, let’s dived 396.44/14 = 28.317, so the result from excel must divided by 28.317

also 4.5720/15 = 0.3048, so the result from excel must divided by 0.3048 before set them to parameter


#9

Well…

That’s not exactly what I wanted but I guess it’s the way to go.

Thanks for the help anyway.


#10

It is in fact a units issue. I believe that the package MEPover has some solutions for this.


#11

The issue is that it’s only a number that now, for the sake of ease, every single value of all the different parameters go into the same Element.setparameter node. So I can’t easily make exceptions, nor do I want to, I can still change the value within Revit itself rather easily.


#12

I don’t believe it’s an exception, I think you need to convert the units before you set the parameter. I’ll see if I can find time to build a graph illustrating what I mean but I’m a bit over my head building in these units. Can you send a stripped down file I can test on?


#13

I do understand you.

But I’m fine converting it Revit. I don’t want to send units into revit, as it concerns dimension values I’m sending in values for lengths as well as integers determining what kind of shape should be used in certain positions and the amount of pipes in the family.

I do very much respect your will to help but it’s not necessary.