Alarska, Try:
string iOpen_full_digit = DoubleToString( NormalizeDouble( iOpen("EURUSD",PERIOD_M1,I),Digits+1 ),Digits ); Comment(" iOpen : ", iOpen_full_digit);regards, cameo
Hi!
I just get started with MQL4 and at them moment I'm trying to access the timeseries. I wanna ask for the High, Low etc. of a specific bar. I do it like this:
I have a broker, that works with five digits for EURUSD, i.e. "1.25573". In my comment I only see 4 digits, so i.e. "1.2557". How can I access the accurate data like it is displayed in MetaTrader when I hover over the bar with the mouse?
Thanks in advance!
Alex
Comments default to printing doubles to only 4 decimal places...you have to convert your doubles into a string containing more than 5 decimal places. Cameo's code does this but I thought you might also want to know why you need to do it.
Comments default to printing doubles to only 4 decimal places...you have to convert your doubles into a string containing more than 5 decimal places. Cameo's code does this but I thought you might also want to know why you need to do it.
"Ask = 1.25 & Bid = 1.2503 " ... Thanks for the explanation though...
I should have written "up to" instead of "only" to be all the more clearer.
I should have written "up to" instead of "only" to be all the more clearer.
Data of double type output with 4 digits after the decimal point. To output with more precision, use the DoubleToStr() function.
Data of double type output with 4 digits after the decimal point. To output with more precision, use the DoubleToStr() function.
:)))))))))). I stand corrected. I never used 5 digits platform come to think of it. if I haven't posted, I would still retain my erred 'concept'. Thx.
Hey guys,
thanks a lot for the help. I didn't get an email, that there were answers, so I kind of forgot about it. I will try it now! :)
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
You agree to website policy and terms of use
Hi!
I just get started with MQL4 and at them moment I'm trying to access the timeseries. I wanna ask for the High, Low etc. of a specific bar. I do it like this:
I have a broker, that works with five digits for EURUSD, i.e. "1.25573". In my comment I only see 4 digits, so i.e. "1.2557". How can I access the accurate data like it is displayed in MetaTrader when I hover over the bar with the mouse?
Thanks in advance!
Alex