for(…) enum{…} makes no sense. You can't execute a declaration.
ENUM_TIMEFRAMES period[10]={PERIOD_M1,PERIOD_M2,PERIOD_M3,PERIOD_M4,PERIOD_M5,PERIOD_M6,PERIOD_M10,PERIOD_M12,PERIOD_M15,PERIOD_M20}; int symbol= SymbolsTotal(1); for(int sym=0;sym<symbol;sym++) { for(int TF=0;TF<10;TF++) { ⋮ } // for } //sym
William Roeder:
for(…) enum{…} makes no sense. You can't execute a declaration.
for(…) enum{…} makes no sense. You can't execute a declaration.
What should i do to loop the timeframes ?
DroidM:
What should i do to loop the timeframes ?
ENUM_TIMEFRAMES period[10]={PERIOD_M1,PERIOD_M2,PERIOD_M3,PERIOD_M4,PERIOD_M5,PERIOD_M6,PERIOD_M10,PERIOD_M12,PERIOD_M15,PERIOD_M20}; int symbol= SymbolsTotal(1); for(int sym=0;sym<symbol;sym++) { for(int TF=0;TF<10;TF++) { //use period[TF] here to define timeframe and get your indicator (e.g. iRSI). ⋮ } // for } //sym
DroidM: What should i do to loop the timeframes ?
Go to bed. When you wake up, you will see that that question was already answered.
William Roeder:
You don't need to be a smartass about it
Go to bed. When you wake up, you will see that that question was already answered.
DroidM:
You don't need to be a smartass about it
Well, he did answer your question. It is just that it appears that you don't understand the answer.
You don't need to be a smartass about it
WindmillMQL:
Well, he did answer your question. It is just that it appears that you don't understand the answer.
And here comes another one.
Well, he did answer your question. It is just that it appears that you don't understand the answer.
DroidM:
And here comes another one.
And here comes another one.
int period[10]={1,2,3,4,5,6,10,12,15,20};
Perhaps something like this...
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
I've been trying to code my strategy into an EA and i use all symbols and all timeframes when using my scalping strategy, i've been trying to do the same with the EA and end up with some error, i am still a little new to coding and my code may be completely wrong but someone help me out. If im using iRSI for example, i want to enter sym for symbol and and TF for period in the parameters.