Bad Bars reading

To add comments, please log in or register
Marco Strazzeri
92
Marco Strazzeri  

I'm using an Expert Advisor which is attached to a chart.

Every new bar it has to real the last 5 bars of ALL timeframes of the same symbol. It comes that sometimes, on the other timeframes, the last bar ( index=1 ) results equal to its preceding bar ( index=2 ), which is a bad reading of chart bars. Read bars are then written on files.

The error never happens when i force bars export manually.

Which can be the cause? Maybe other timeframe bars are still not loaded while the EA is reading them?

Alain Verleyen
38661
Alain Verleyen  
Marco Strazzeri:

I'm using an Expert Advisor which is attached to a chart.

Every new bar it has to read the last 5 bars of ALL timeframes of the same symbol. It comes that sometimes, on the other timeframes, the last bar ( index=1 ) results equal to its preceding bar ( index=2 ), which is a bad reading of chart bars. Read bars are then written on files.

"Read" what exactly ?

The error never happens when i force bars export manually.

What that means ?
Marco Strazzeri
92
Marco Strazzeri  

By "Read" i mean reading any value of the bar ( open, close, etc. ).

By "export manually" i mean clicking on a button on the chart which calls the exact same function, which is the one that read and exports data and generates the explained problem

To add comments, please log in or register