What I do is count the number of buy_orders and the number of sell_orders.
If the number of buy_order>sell_orders then return() or dont-place-buy_orders.
Vice-versa for sell logic.
What I do is count the number of buy_orders and the number of sell_orders.
If the number of buy_order>sell_orders then return() or dont-place-buy_orders.
Vice-versa for sell logic.
Hello everybody. I would like to see if you can help me with a problem i've been having.
I have this piece of code so that the EA only executes 1 buy and 1 sell per symbol.
Now, what i need to do is the EA trade when pairs are done. What I mean with a pair is 1 buy and 1 sell executed. When these two orders are executed allow another pair.
I will try to resume the process so it is clear:
1) BuyStop order is open.
2) Only can be open a SellStop...It is open now
3) The EA now allow more trade (the same, 1 buy and 1 sell only).
4) SellStop order is open.
5) Only can be open a BuyStop... It is open now
6) The EA now allow more trade (the same, 1 buy and 1 sell).
7) And so on...
That is why i thought that an algorithm that count the number of trades per symbol, or maybe one that count the number of buys and sells per symbol, so that i know when it should allow the next pair.
So, what do you think? Can you help me??

- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
You agree to website policy and terms of use
Hello everybody. I would like to see if you can help me with a problem i've been having.
I have this piece of code so that the EA only executes 1 buy and 1 sell per symbol.
Now, what i need to do is the EA trade when pairs are done. What I mean with a pair is 1 buy and 1 sell executed. When these two orders are executed allow another pair.
I will try to resume the process so it is clear:
1) BuyStop order is open.
2) Only can be open a SellStop...It is open now
3) The EA now allow more trade (the same, 1 buy and 1 sell only).
4) SellStop order is open.
5) Only can be open a BuyStop... It is open now
6) The EA now allow more trade (the same, 1 buy and 1 sell).
7) And so on...
That is why i thought that an algorithm that count the number of trades per symbol, or maybe one that count the number of buys and sells per symbol, so that i know when it should allow the next pair.
So, what do you think? Can you help me??