What RefreshRates() updates - page 5

 

I wanted to give you some good advice.

It's just that the way you approach coding has a big impact on the end result. After a while, you'll have to make crutches because of the crutches you've already made.

But I'm sorry if it's unnecessary.

 
PapaYozh:

I wanted to give you some good advice.

It's just that the way you approach coding has a big impact on the end result. After a while, you'll have to make crutches because of the crutches you've already made.

But sorry if that's redundant.

MT4 is a dark box, and I only judge what happens there by testing under real conditions. Initially I didn't use sleep at all, but when I was getting bullshit on some hour bars I added sleep and the problem disappeared. I don't know in what order and how the MT4 time series is updated. Let me be scolded by "witnesses of the purest true code", the main thing is that I have solved my problems, which I am sharing.

 
Mikhail Nazarenko:

MT4 is a dark box and I can only judge what happens there by testing in real conditions. Initially I didn't use sleep at all, but when I was getting bullshit on some hour bars I added sleep and the problem disappeared. I don't know in what order and how the MT4 time series is updated. I am not going to be scolded by "witnesses of the purest true code", the main thing is that I have solved my problems and I'm sharing my results with them.

If I had studied the documentation before coding, many questions would not have arisen.

If there are no open charts of periods other than the current one, the time-series of these other periods are updated (start updating) only when they are called.

Because of this, we have to synchronize timeframes in the Expert Advisor, and the easiest (but not the most efficient) way to do this - to address all higher timeframes if not every tick, then at least once a minute.

And to check if they are synchronized we should compare iTime() values.

 
Aleksey Mavrin:

If you study the documentation before coding, many questions would not arise.

If the charts of other periods than the current chart are not opened, the time series of these other periods are updated (start to be updated) only when they are accessed.

Because of this, we have to synchronize timeframes in the Expert Advisor, and the easiest (but not the most efficient) way to do this - to address all higher timeframes if not every tick, then at least once a minute.

And to check if they are synchronized, we should compare iTime() values.

Damn, I want this documentation. May I have the link, please?

 
Mikhail Nazarenko:

Man, I want that documentation. Can I have the link please?

https://docs.mql4.com/ru
Справочник MQL4
Справочник MQL4
  • docs.mql4.com
Справочник MQL4
 
Roman:
https://docs.mql4.com/ru
Where is it about updating the time series. I couldn't find it. Only knew about it from the forum.
 
Valeriy Yastremskiy:
Where is it about updating the time series. Couldn't find it. Only knew about it from the forum.

I don't know ))
The request was for a link to documentation.

 
Valeriy Yastremskiy:
Where is it about updating the time series. Not to be found. Only knew about it from the forum.

Yes, there is not everything in the documentation, or rather there are few explanations and examples. And my words are based on the combined experience of the forum and experiments, probably mixed with the 5).

Maybe I was right to say about documentation in the following way - if you rely on everything that is not inconsistently specified in it, you can determine the actual behavior in a given situation with rather simple tests.

Many surprises from guessing how it should/would work.

 
Aleksey Mavrin:

Yes, there is not everything in the documentation, or rather there are few explanations and examples. And my words are based on the combined experience of the forum and experiments, probably mixed with the 5).

Maybe I was right to say about documentation in the following way - if you rely on everything that is not inconsistently specified in it, you can determine the actual behavior in a given situation with rather simple tests.

Many surprises from guessing how it should/would work.

Only by the docs, you cannot get far without a forum.... The usual problem of product development and doc compliance for each change)
 
Aleksey Mavrin:

Yes, there is not everything in the documentation, or rather there are few explanations and examples. And my words are based on the combined experience of the forum and experiments, probably mixed with the 5).

Maybe I was right to say about documentation in the following way - if you rely on everything that is not inconsistently specified in it, you can determine the actual behavior in a given situation with rather simple tests.

Many surprises from guessing how it should/would work.

If you start to teach, so help, confirm with code, tests, a link to a forum topic or documentation. Everything else is brain masturbation.