LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

add decimal to string value

I need help changing the format of some data that is in a string.  I am reading data from a serial device and want to add a decimal to the data.
 
Example:
 
Data read = 2345
Need to display it as 23.45
 
I tried "Format Value", but can't seem to get it to work.  Is that the right thing to use?  Any help would be appreciated
 
 
0 Kudos
Message 1 of 4
(3,133 Views)
Are you just scaling by 100? Why not convert the string to a number? Do you need to convert it back to a string?
0 Kudos
Message 2 of 4
(3,122 Views)
Just scan and divide by 100.
 
Of course if you want a string at the end, there are several options, e.g.:
 
 

Message Edited by altenbach on 03-23-2007 09:28 AM

0 Kudos
Message 3 of 4
(3,118 Views)

Sima and Altenbach,

Thank you for your suggestions.  I was over thinking the solution.  I converted the string to a number, then divided by 100.

Thanks again!!

 

0 Kudos
Message 4 of 4
(3,066 Views)