EventSetMillisecondTimer(500);
And don't forget to call
ChartRedraw();
After you modified objects.
Marco vd Heijden:
And don't forget to call
After you modified objects.

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
Dear MT-friends,
I programmed a simple clock-indicator that should show the current time in HH:MM:SS-format in the right upper corner of the chart. So far so good.
The problem is that this clock is supposed to update every second (EventSetTimer(1)), but it doesn't: there are many, frequent omissions ranging from one to several seconds. It looks like rather than updating as expected OnTimer (where I placed the code) and thus every second, it updates OnCalculate (i.e. on every tick, which can be more or less than every second).
Why? Any ideas how to make this work on every second?
Thanks