Community
Inventor Forum
Welcome to Autodesk’s Inventor Forums. Share your knowledge, ask questions, and explore popular Inventor topics.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Inventor parameter.value in cm instead of default units

0 REPLIES 0
Reply
Message 1 of 1
Arnold82
373 Views, 0 Replies

Inventor parameter.value in cm instead of default units

Hello,

 

I am exporting many parameters to my skeleton model

If I export a parameter with value 1mm, the result is 0.1

 

I made a quickfix by making all my parameters unitless, but this is not how i would like it.

 

I am testing a bit in ilogic to fix this, because i want to use degrees and milimeters instead of unitless.

 

Dim oDoc As Document = ThisDoc.Document
Dim UserParams As UserParameters = oDoc.ComponentDefinition.Parameters.UserParameters
Dim UserParam As UserParameter


UserParams.AddByExpression("Testparam", "1", UnitsTypeEnum.kDefaultDisplayLengthUnits)
MsgBox(UserParams.Item("Testparam").Value)

 

My default length unit is 'mm' and 1 mm becomes 0.1mm when I sent it to my skeleton.

 

 

My question:

 

How can I make it possible that the parameter.Value = 1 regardless of wheter the parameter is mm, cm, inches or whatever?

 

 

Thanks in advance,

 

Arnold

0 REPLIES 0

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Autodesk Design & Make Report