LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Bytes to read

Hello everyone. I can go into "Data Types" settings with a Numeric Controller, but i don't need a numeric controller, because i have to read the bytes. So how do i change a simple string controller to "Unsigned Long" ?. There isn't any Data Types settings for a simple String controller. 

Best regards

Oesen
0 Kudos
Message 1 of 3
(2,029 Views)

That is because a string control is a String and nothing else. A number control has different numeric subtypes and that defines what range that number can hold as well as how it is stored in memory. A string control is simply a string!

 

If you want to display numbers in a string you have to format the number into a string, using for instance Format into String or similar. And if you want to make sure the user can only enter numbers you better use a numeric control. If for any reasons you need a string in the program after that you can always format that number into a string where needed.

Rolf Kalbermatter
My Blog
Message 2 of 3
(2,024 Views)

This question is probably related to this one: http://forums.ni.com/t5/LabVIEW/Three-devices-with-one-computer/m-p/2144666

 

If so, then you will clearly be reading strings from the serial port. You would then need to convert them into numbers. How you do that depends on what the actual contents of the string is.

0 Kudos
Message 3 of 3
(2,010 Views)