LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Decimal rounding while creating a double numeric constant when VI Scripting

Solved!
Go to solution

Hi guys,

 

First time poster here, so please excuse any faux pas. I am using LabVIEW Professional Development System 2013 SP1 on a Windows 7 machine; I am somewhat new to LabVIEW, but have a good background in other programming languages. I recently stumbled across VI Scripting and have been playing around with it. As the title suggests, I've been having trouble creating numeric constants whose decimal values are not rounded. It seems to me that as I pass the double (42.1) to the Property Node, it somehow gets cast to an integer. I tried setting the AdaptToEnteredData value to True, but I think this only affects the numeric object in the newly created VI (Output). It seems that the problem is in how I pass the numerical value to the Property Node in the original VI, but I don't really know how else to do it besides the way I've presented.

 

Please let me know if there's any other necessary information, and thanks for your help!

Sebastian

Download All
0 Kudos
Message 1 of 3
(3,660 Views)
Solution
Accepted by topic author sebastianhp

Property nodes execute from top down. Move the Representation property above the Value property.

 

Lynn

 

Scripting.png

Message 2 of 3
(3,619 Views)

Smiley Surprised Gotta love it when the solution is so simple. Thanks for the quick reply!

0 Kudos
Message 3 of 3
(3,559 Views)