cleon:
Hello,
MQL rounds decimal numbers like 112.80 to 112.8 automatically (at least it looks like), but I need the value to be shown like 112.80 (with the zero), so I tried to use normalizedouble function with 2 digits (or 4 to the other pairs), but it only shows 1 digits when the last digit is a 0 (zero). How can I force to always show .00 or .0000 in any value in any currency ? I already used "Digits" on NormalizeDouble so it can match the current pair and nothing.
Thank you.
Cleon
Use DoubleToStr() function.
Hello,
MQL rounds decimal numbers like 112.80 to 112.8 automatically (at least it looks like), but I need the value to be shown like 112.80 (with the zero), so I tried to use normalizedouble function with 2 digits (or 4 to the other pairs), but it only shows 1 digits when the last digit is a 0 (zero). How can I force to always show .00 or .0000 in any value in any currency ? I already used "Digits" on NormalizeDouble so it can match the current pair and nothing.
Thank you.
Cleon
But when converting it to a string I can not use it in calculations, because it's
a string?
Thank you.
Thank you.
cleon:
But when converting it to a string I can not use it in calculations, because it's a string?
Thank you.
But for calculations it does not matter if it is 112.80 or 112.8, does it? Or I'm
missing something.
But when converting it to a string I can not use it in calculations, because it's a string?
Thank you.

You are missing trading opportunities:
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
Registration
Log in
You agree to website policy and terms of use
If you do not have an account, please register
MQL rounds decimal numbers like 112.80 to 112.8 automatically (at least it looks like), but I need the value to be shown like 112.80 (with the zero), so I tried to use normalizedouble function with 2 digits (or 4 to the other pairs), but it only shows 1 digits when the last digit is a 0 (zero). How can I force to always show .00 or .0000 in any value in any currency ? I already used "Digits" on NormalizeDouble so it can match the current pair and nothing.
Thank you.
Cleon