How to quickly to open two order?

 

Hello,everyone.

I want to design to open two order in the same time, open buy first then open sell in the same time. But always only one order can be opened, the other one cannot be opened? why?

 

short answer is that only allowed to send one order at a time - one trading thread allowed:

Only one execution thread is provided in the client terminal to perform trades. This means that the client terminal can simultaneously work only with one request. If there are several Expert Advisors or scripts trading in the client terminal and no program has passed a trade request to the client terminal, the trade requests of all other Expert Advisors and scripts will be rejected until the client terminal completes processing the current request, i.e., until the trade thread is free.

longer answer is here: MQL4 Book - Common Way of Making Trades

Reason: