LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Parse string into two doubles

Solved!
Go to solution

Hello again all,

 

I'm trying to take a string of numbers that can be anywhere from -999999.999999 to +999999.99999 and separate them into two doubles. For example, if a user input -10000 - -10000, the two doubles would be -10000 and -10000. If the user input -10.11111 - +20.00111 it would come out -10.11111 and 20.00111. The "Extract Numbers" VI does the parsing perfectly, but I need a way to return the results into two doubles instead of an array of doubles. I also need the results to return all the digits past the decimal point for accuracy reasons. I'm using this code inside one of my states in a state machine and the driver I'm using only accepts doubles.

 

Attached is the code from the "Extract Numbers" VI.Thanks everyone!

 

Extract Numbers.jpg

0 Kudos
Message 1 of 3
(2,725 Views)
Solution
Accepted by topic author buickgn

Hi buickgn,

 

when your code works you only need to use IndexArray on the outputs. Otherwise you may try that one:

check.png

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
Message 2 of 3
(2,720 Views)

Thank you so much GerdW!!

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