Float.parseFloat, Type mismatch: cannot convert from String to Float

One Star

Float.parseFloat, Type mismatch: cannot convert from String to Float

Dear all,
I try to cast from string to float.
I use java code in a tJavaFlex component : 
row2.coord = Float.parseFloat(row1.coord);

Of course, I select the right type for input (string) and output(float)
But i have an error : 
Type mismatch: cannot convert from String to Float

Thank you in advance for your idea!
Six Stars JR
Six Stars

Re: Float.parseFloat, Type mismatch: cannot convert from String to Float

I suggest to use the tConvertType component instead of diving into custom Java coding. Its use is pretty straightforward and it does what you desire.
Twelve Stars

Re: Float.parseFloat, Type mismatch: cannot convert from String to Float

use 
Float.valueOf(row1.coord)
-----------