![Get in touch with developers using Service Desk! Get in touch with developers using Service Desk!](/i/community/logo_mql5_small.png)
- www.mql5.com
Did you read documentation?
Normally, this function must be called from the OnInit() function or from a class constructor.
Yes i did, but to quick. :)
i didn't say it is a bug, i said that it looks like a bug.
IMO, there are no reasons to limit changing of timer to OnInit(), from programmers point of view.
So from my point of view, and obviously Pr1mer's point, this looks like a bug.
However, in your implementation, you have done so, and documented it.
So Pr1mer, why didn't you read the documentation? :)
graziani, we have couple servicedesk requests from you look like you don't read documentation. he-he
Pr1mer exposed Tester logs (not real work logs). And Strategy Tester has some limitations. For example test events - ticks and timers - are collected for some time (1 hour) and cannot be removed from the collection.
There is very strange to use timer with such way. Just use it with minimum step and dont change this step
graziani, we have couple servicedesk requests from you look like you don't read documentation. he-he
Show me one and you have a lunch on me. (Except the one I closed, because thats obviously brokers fault).
For example test events - ticks and timers - are collected for some time (1 hour) and cannot be removed from the collection.
graziani - thanks for your input, stringo - thank you for explanation
I need such a functionality to simulate my past trades based on my trade history. I wanted my EA to wait in periods between trades - these are variable so changing timer would be necessary.
![MQL5 - Language of trade strategies built-in the MetaTrader 5 client terminal](https://c.mql5.com/i/registerlandings/logo-2.png)
- 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 came across a strange behavior of timer which I cannot comprehend.
When I run the following simple EA:
I receive the expected behavior, i.e. OnTimer() function is called with expected increasing periods from 0.5 h to 3 h:
However, when I reverse the logic to decreasing periods:
I get the following output:
Where do these extra calls to OnTimer come from? It seems that the first calls to function EventKillTimer() are not effective.
Is it a bug or am I missing something here?
Tested on build 712.