I have tried to place these lines in the MACD Sample, but always I have mistakes. string symbols = { "GBPUSD", "EURUSD", ... }; // all symbols to trade int pair = -1; string tradeSymbol; // current symbol to trade void start() { pair = (pair + 1) % ArraySize(symbols); tradeSymbol = symbols[pair]; // 1st tick: GBPUSD, 2nd tick: EURUSD, and so on ... ... if (...) { OrderSend(tradeSymbol, . ..); } ... } ... Someone can say to me since(as,like) it(he) would(still) remain correctly compiled? Thanks to all.
- trading multiple currency pair within the same EA
- Placing Multiple currency order using one EA on one chart
- Problem with OrderSend - invalid symbol
Make sure that Bid or Ask for OrderSend function are appropriate for your symbols.
Instead of Bid or Ask use MarketInfo function
string symbols[]={ "GBPUSD", "EURUSD" }; static int ticknum=0; if(ticknum<ArraySize(symbols)) { OrderSend(symbols[ticknum],OP_BUY,volume,MarketInfo(symbols[ticknum],MODE_ASK),...); ticknum++; }
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