There is no ordersend in your code.
If you want to open orders on different pairs you can use SymbolName(pos,1)
this isn't my entire code Marco, it's just the portion that regulates how many trades are placed at a time...
Maybe it's a good idea to post all code.
This code only increments result whenever a magic number match appears.
If you want your EA to trade multiple pairs (again) you can use SymbolName(pos,1)
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
Currently, I have been using this code...
//-------------------------------------------------------------------
int TotalOrdersCount()
{
int result=0;
for(int i=0;i<OrdersTotal();i++)
{
OrderSelect(i,SELECT_BY_POS,MODE_TRADES);
if (OrderMagicNumber()==MagicNumber) result++;
//------------------------------------------------------------------
it has worked fine, all I do is switch magic numbers for each currency pair. But I'm improving my EAs but I don't know how to write it.
I want my EA to open different trades on different pairs, but only one per pair. How do I do it?