Using MQL4, how can I get the profit / loss for the most recently closed position for a specific pair?
- Check if there is already an open position of a specific pair
- Elite indicators :)
- How can I get the highest price reached by position (to calculate profit loss)
- Find "most recently closed position for a specific pair"
- Select that order.
- Profit = OrderProfit() + OrderCommission() + OrderSwap
How can I find the "most recently closed position for a specific pair"?
deklin:
How can I find the "most recently closed position for a specific pair"?
How can I find the "most recently closed position for a specific pair"?
Cycle through OrdersHistoryTotal() by using OrderSelect() and for specific pair OrderSymbol()

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