and work around Chart Event For MT4 Backtester - Strategy Tester - MQL4 and MetaTrader 4 - MQL4 programming forum #7 2016.04.03
and How to use OnChartEvent buttons to work in Tester - MQL4 and MetaTrader 4 - MQL4 programming forum - Page 2 #11 2019.04.28
See In backtest OnTimer() not performs - MQL4 and MetaTrader 4 - MQL4 programming forum #3 2014.02.21
and work around Chart Event For MT4 Backtester - Strategy Tester - MQL4 and MetaTrader 4 - MQL4 programming forum #7 2016.04.03
and How to use OnChartEvent buttons to work in Tester - MQL4 and MetaTrader 4 - MQL4 programming forum - Page 2 #11 2019.04.28
Sorry, I forgot to mention that it is MQL5.
"The minimum interval of 1000 milliseconds is used in the strategy tester."
- www.mql5.com
I have an EA what uses OnTimer and I want run tests more optimized. To do it, I though about use the OnTimer only in "Each Tick" modes and disable the timer to use OnTick to call OnTimer in OHLC and only open candle modes. I was unable to find a constant to show me this information.
Is there any way for the EA to know what type of modeling is being performed in the test?
Not with mql function. You need to use WinAPI call, check the Codebase, someone already did it.
Thanks Alain.
But I avoid to add dll's and low-level dependencies because of the complexity to manage de EA (install in other environments, etc). I'll set the modeling mode as a EA input that will exists only when I compile with a specific #define to control a #ifdef block.
C'est la vie
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
You agree to website policy and terms of use
I have an EA what uses OnTimer and I want run tests more optimized. To do it, I though about use the OnTimer only in "Each Tick" modes and disable the timer to use OnTick to call OnTimer in OHLC and only open candle modes. I was unable to find a constant to show me this information.
Is there any way for the EA to know what type of modeling is being performed in the test?