wiki:Docs/Prog/Manual/ApplicationLibraries/lib825ev/String/StrToFloat

Version 3 (modified by Don Wilson, 14 years ago) ( diff )

--

StrToFloat

Convert string to floating point number

float StrToFloat(string& strVal);

Parameters

  • strVal - string containing a floating point number

Return Value

  • Returns the floating point value of the string

Remarks

If the string does not contain a valid floating point number the result will be zero.

Example

string strVal = "12.45";
float fVal = StrToFloat(strVal);

See Also

Note: See TracWiki for help on using the wiki.