LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How can I extract high and low parts of a string that represents a 64bits decimal number?

I want to extract the high and low parts to interpret it and convert to binary code, but such a hugh number (represented by a string) isn't easy to extract from the string directly its high and low parts.
0 Kudos
Message 1 of 3
(3,021 Views)
If the string you want to parse is 64 characters, then use the String Subset function (String palette) twice. To get the first 32 characters, set offset to 0 and length to 32. To get the last 32 characters, set offset to 32 and length to 32.
0 Kudos
Message 2 of 3
(3,021 Views)
LabVIEW can't handle a 64-bit integer. You will have to store it as two 32-bit integers. If you need exact math on those 64-bit intergers you will have to make up your own routines to handle the carries and what not. If you just need pretty good accuracy, covert both 32-bit integers to double, multiply the upper 32-bit number by 2*32 (also a double) and then add the lower 32-bit number to it.

Good luck.
0 Kudos
Message 3 of 3
(3,021 Views)