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
Hi, I'm trying create a script that loads data from all pairs from certain timeframes.
The logic is :
Attach script to Window A
Script Tells Window B -->
Load Pair X
Load Time Frame Y
ChartNavigate to shift -99999
if Time of First bar after ChartNavigate is still after 26 March 2018 00:00 then do ChartNavigate again
When done, shift to next time frame, when done, shift to the next pair. untill all pairs in market watch is completed
The issue is after each loop, the time (using either iBars or CHART_FIRST_VISIBLE_BAR value) value is when the data of Window,Pair & Timeframe is loaded, looping does not udpates the value of this.
Attach is the script (it works because a trick, that if I've hit the most left bar, i skip to next pair. but that means the pair loads way more data than I requested)
and below is snippet of the code
should be something like
but I'm using something like this instead
I hope someone can give me an explantion. is this an MQL4 bug? that prevents new iBars value to be loaded during a running script? Anyone have any workarounds?