# ICustom return strange numbers

I have an iCustom inside an expert,

When I execute the iCustom, I receive this message

2022.10.30 21:11:53.789 2021.01.04 12:00:00  Big Trend V140 GBPJPYi,H1: Float Gain Meter Buf0CtAchatCt Float0 2.3e-05 Float1 5.7e-05 Float2 7.9e-05 Float3 9.6e-05

How can I convert this number in double.

Thank you.

fbertran123: I have an iCustom inside an expert, When I execute the iCustom, I receive this message. 2022.10.30 21:11:53.789 2021.01.04 12:00:00  Big Trend V140 GBPJPYi,H1: Float Gain Meter Buf0CtAchatCt Float0 2.3e-05 Float1 5.7e-05 Float2 7.9e-05 Float3 9.6e-05.How can I convert this number in double.

It is already a double, otherwise it would not print as such. Explain in more detail and show your code, otherwise we can only speculate.

fbertran123:

How can I convert this number in double.

It is already a double. To print use DoubleToString().

Fernando Carreiro #:

It is already a double, otherwise it would not print as such. Explain in more detail and show your code, otherwise we can only speculate.

This is my code

Print("Achat Floating Achat Ct 4 2"," Float0 ",FloatingBuf0CtAchatCt[0]," float1 ",FloatingBuf0CtAchatCt[1]," Float2 ",FloatingBuf0CtAchatCt[2]," Float3 ",FloatingBuf0CtAchatCt[3]);

fbertran123 #: This is my code ...
```// Example code to print a fixed point "double" to number of digits of the current symbol
Print( "FloatingBuf0CtAchatCt[0] = ", DoubleToString( FloatingBuf0CtAchatCt[0], _Digits ) );

// Example code to print a fixed point "double" to 2 more digits than that of the current symbol
Print( "FloatingBuf0CtAchatCt[0] = ", DoubleToString( FloatingBuf0CtAchatCt[0], _Digits + 2 ) );
```

The code above is untested, and uncompiled. It was simply typed out by memory.

Please note, that the function DoubleToString is only required for outputting the value as a string. The variable itself is already in double precession floating point binary representation and needs no conversion.

EDIT: When adding code in your posts, please use the "</>" icon or Alt-S. Don't simply paste code as plain text. It makes it difficult to read. Please edit your previous post so that your code is properly placed.
Reason: