TimeCurrent is the last server response, so any tick on any instrument in the Market Watch can update it. I do not expect the RefreshRates has any effect.
TimeLocal is just the internal clock, it increments regardless of your code.
From the documentation
From the documentation
And? There is no answers.
Are you moderator? Why you do not delete flood?
And? There is no answers.
Are you moderator? Why you do not delete flood?
You have been given your answer
About TimeCurrent answers are founded.
So new tick not changes TimeCurrent while code running, but RefreshRates do it.
https://book.mql4.com/en/functions/datetime
Each tick is characterized with its own value of the server time that can be obtained using the TimeCurrent() function. During the execution, this value can only be changed as a result of the RefreshRates() function call.

- book.mql4.com
So I only need to know about TimeLocal().
So I only need to know about TimeLocal().
TimeLocal is just the internal clock, it increments regardless of your code.
So I only need to know about TimeLocal().
TimeLocal() updates each time while code running in OnTimer().
TimeCurrent() not updates each time while code running in OnTick(). But after RefreshRates() new call of TimeCurrent() updates it.

- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
You agree to website policy and terms of use
If call TimeCurrent() in start of OnTick() and in the end. Do TimeCurrent() changes if in interval of code running there will be tick?
Same question. but 1 additional thing. Between 2 TimeCurrents there RefreshRates().
{
datetime time=TimeCurrent();
//new tick
//new tick+RefreshRates()
datetime time2=TimeCurrent();
//time==time2 ???????????
}
If call TimeLocal() in start of OnTimer() and in the end. Do TimeLocal() changes if in interval of code running will be 2 seconds(on timer is 1 second)?
Same question. but 1 additional thing. Between 2 TimeLocals there RefreshRates().
void OnTimer()
datetime time2=TimeCurrent();{
datetime time=TimeLocal();
//code running 2 seconds
//code running 2 seconds+RefreshRates()
//time==time2 ???????????
}