LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

show ascii instead of hex

the string indicator shows:
for example:
31 62
Is there an easy way to show "1b" instead
thanks
/Ape
0 Kudos
Message 1 of 5
(2,813 Views)
Hi,

make sure that the string indicator is configured as normal display and
not hex display. If the 31 62 is shows as normal display you can devide
it in two string "31" and "62" and use a string function to turn them
into U8, bild an array of them and turn again into strin with the "byte
array in string" function.

Niko
Message 2 of 5
(2,813 Views)
With one of the tool control icons on the string indicator, right click your mouse and select "Normal Display." This will immediately convert 31 62 to 1b.
Message 3 of 5
(2,813 Views)
Aderogba wrote in message news:<50650000000500000073CF0000-1042324653000@exchange.ni.com>...
> With one of the tool control icons on the string indicator, right
> click your mouse and select "Normal Display." This will immediately
> convert 31 62 to 1b.

Thanks, but its already normal display.
sorry for not include that info in the earlier post
0 Kudos
Message 4 of 5
(2,813 Views)
The simplist way is somewhat slower than other ways I am sure. But here it is. First convert the numbers to 8bit (ushort)integers, using scan from string in a loop, placing the results into an array. Then convert the array of ushort to a string using the convert array to string function.
Jon D
Certified LabVIEW Developer.
0 Kudos
Message 5 of 5
(2,813 Views)