try calling
RefreshRates() between the orders.
the main problem that you can't guarantee to open 2 orders at the same time without using Limit/Stop Orders.
How can i get accurate splippage for my EA?
These days not all brokers use slippage. Specifically, brokers that claim to be ECN's or use some sort of a bridge usually ignore slippage. This should be clearly mentioned in their website and the contract u signed when u opened an account.
If your broker does use slippage then u should understand that there is a fine balance between slippage and the chance of getting filled - the smaller the slippage the smaller the chance of being filled. There's also no general value of slippage that 'is best' for all brokers/market-conditions.
The things u can do to ensure minimum slippage:
- Try to trade from a computer with the lowest possible latency to your broker (and generally a high quality connection - no drops, minimum hops, etc.).
- Prefer pending orders over market orders.
- Try different slippage values and collect success statistics... Over time u should be able to find the 'best' value of slippage for your broker (and perhaps also for different market conditions).

- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
You agree to website policy and terms of use
How can i get accurate splippage for my EA? The problem it has is that it places one order sometimes and it two sometimes and i want it to be placing buy and sell at the same time so i think the problem is the splippage. But if am wrong let me know and if there is a way i can be generating splippage without having fixed one, please help me. thanks