Avery Horton: Why does MT5 not return 60 for H1, 240 for H4 and 1440 for D1?
It's an enumeration, should be numbers like 0, 1, 2, …
The values are irrevalent. You shouldn't care. If you want 1440, just use PeriodSeconds(PERIOD_D1)/60
William Roeder:
It's an enumeration, should be numbers like 0, 1, 2, …
The values are irrevalent. You shouldn't care. If you want 1440, just use PeriodSeconds(PERIOD_D1)/60
You know, I had thought it strange that they don't use the same enumerations as they do in MQL4.
Your solution had never occurred to me. :)
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
Why does MT5 not return 60 for H1, 240 for H4 and 1440 for D1?
Comment(
"PERIOD_CURRENT " + PERIOD_CURRENT + "\n" +
"PERIOD_M1 " + PERIOD_M1 + "\n" +
"PERIOD_M5 " + PERIOD_M5 + "\n" +
"PERIOD_M15 " + PERIOD_M15 + "\n" +
"PERIOD_M30 " + PERIOD_M30 + "\n" +
"PERIOD_H1 " + PERIOD_H1 + "\n" +
"PERIOD_H4 " + PERIOD_H4 + "\n" +
"PERIOD_D1 " + PERIOD_D1 + "\n" +
"");