String should be Float with loaderInfo

Hello,

I have this error

trace(Std.int( Lib.current.loaderInfo.parameters.size ));
src/Main.hx:167: characters 18-61 : String should be Float
src/Main.hx:167: characters 18-61 : For function argument 'x'

size = “3456”

Thanks

Use Std.parseInt() rather than Std.int().

return ‘undefined’ and null

this code work

Std.int( Reflect.field( Lib.current.loaderInfo.parameters, "size" ) )

Could you run the following, and see what it traces?

var size = Lib.current.loaderInfo.parameters.size;
trace ("'" + size + "'");
trace (Std.parseInt (size));

Thanks, it work now.