Our full technical support staff does not monitor this forum. If you need assistance from a member of our staff, please submit your question from the Ask a Question page.


Log in or register to post/reply in the forum.

Uppersit of FormatFloat


MortenS Mar 24, 2010 07:59 PM

Hi

Does CRBasic got a uppsit function of the FormatFlow ?

I want to convert a string containing a numeric value into a numeric type (eg Long)

Regards

Morten


Dana Mar 24, 2010 08:44 PM

The CRX000 dataloggers attempt to convert from string to numeric or numeric to string automatically, wherever possible. So if you place a string into a long variable, the conversion should be done.

The caveat to this is that automatic conversion of an alphanumeric string will stop when the first alpha character is found. If the string begins with alpha characters and SplitStr is not used to strip off those characters, then NAN will be stored.

Also, if using an operator on strings & numerics the following applies:

string <operator> float = string

float <operator> string = float

Regards,

Dana W.


MortenS Mar 24, 2010 08:49 PM

Hi Dana

That was too easy :-)

But it worked...
thanks

Mrten

Log in or register to post/reply in the forum.