Hi,
I am trying to code a Multi-Symbol function and I need some help with it.
I have given the pairs an option like this one:
Now I would like the pairs to pass through a bool or void or int to go to OnTick afterwards. The EA has more than 10 indicators and using the common Multi-Pair codes does not seem that suitable.
FIRST: How would it store or calculate each of the indicators parameters?
SECOND: How can I make it loop? Checking every pair activated?
hi,
one from my best ways is this one:
input string symbolTab="GBPUSD;EURUSD;USDJPY";//Symbols To Trade string symbols[]; int copy[]; int OnInit() { int symbolsNumber=StringSplit(symbolTab,';',symbols); ArrayResize(copy,symbolsNumber); for(int i=0;i<symbolsNumber;i++) copy[i]=iCustom(symbols[i],...,............); ....... ....... }
than you should use the same "for(int i......)" in the rest of program.
but please never delete the post after you get the answer, i am not working for anyone, i am helping all. (it happened with some topics)
hi,
one from my best ways is this one:
than you should use the same "for(int i......)" in the rest of program.
but please never delete the post after you get the answer, i am not working for anyone, i am helping all. (it happened with some topics)
Looks nice. I am going to try and decipher it first to see how to apply it.
Thanks a lot. As for me, I will certainly not delete it.
I cannot implement it to all the handlers
didn't get you, can you explain,
I was thinking of creating a list like: Pair1, Pair2, Pair3...
I am attaching a code that does not work, but you might see some of the logic of what I am thinking
void TradePairs() { int i; if((!Trade_Pair1)&&(!Trade_Pair2)&&(!Trade_Pair3)&&(!Trade_Pair4)&&(!Trade_Pair5)&&(!Trade_Pair6)&&(!Trade_Pair7)&&(!Trade_Pair8)&&(!Trade_Pair9)&&(!Trade_Pair10)&&(!Trade_Pair11)&&(!Trade_Pair12)&&(!Trade_Pair13)&&(!Trade_Pair14)&&(!Trade_Pair15)&&(!Trade_Pair16)&&(!Trade_Pair17)&&(!Trade_Pair18)&&(!Trade_Pair19)&&(!Trade_Pair20)&&(!Trade_Pair21)&&(!Trade_Pair22)&&(!Trade_Pair23)&&(!Trade_Pair24)&&(!Trade_Pair25)) Sym=Symbol(); for(i=0; i<25; i++) { Sym=Pair1, Pair2, Pair3; } if(Trade_Pair1) { Sym=EnumToString(Pair1); } if(Trade_Pair2) { Sym=EnumToString(Pair2); } if(Trade_Pair3) { Sym=EnumToString(Pair3); } }
It could be a good idea telling the code to take the first option READ the rest, come back for the second option then READ, etc.
Is that possible?
It could be a good idea telling the code to take the first option READ the rest, come back for the second option then READ, etc.
Is that possible?
hi,
sorry but i couldn't see clearly what you meant from the code, because it is full of syntaxes errors.
but anyway, do you want to know how to continue my suggested code? (if yes i will continue writing it)
ADVICE:-- i have more than 7 years experience in coding, butu i have never written a code in that lengh-- ALWAYS try to not work a lot and write the lowest possible lines specially at the start
than after that you will focus on RAM and CPU use.
wish you the best :)
hi,
sorry but i couldn't see clearly what you meant from the code, because it is full of syntaxes errors.
but anyway, do you want to know how to continue my suggested code? (if yes i will continue writing it)
ADVICE:-- i have more than 7 years experience in coding, butu i have never written a code in that lengh-- ALWAYS try to not work a lot and write the lowest possible lines specially at the start
than after that you will focus on RAM and CPU use.
wish you the best :)
Ok. Let's try.
Ok. Let's try.
Ok. Let's try.
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
You agree to website policy and terms of use
Hi,
I am trying to code a Multi-Symbol function and I need some help with it.
I have given the pairs an option like this one:
Now I would like the pairs to pass through a bool or void or int to go to OnTick afterwards. The EA has more than 10 indicators and using the common Multi-Pair codes does not seem that suitable.
FIRST: How would it store or calculate each of the indicators parameters?
SECOND: How can I make it loop? Checking every pair activated?