What is the error in this code? I want to calculate the number of open orders (Buystops/sellstops or Buylimits/selllimits)
Sathish Justin: Some experts please tell what is wrong with the below code, it is not counting the open orders?
The name of the function says it all ... HistoryOrdersTotal
"History" is "old", not "current". Currently open orders are not in the "history".
Instead use ...
Returns the number of orders
Documentation on MQL5: Trade Functions / OrdersTotal
- www.mql5.com
OrdersTotal - Trade Functions - MQL5 Reference - Reference on algorithmic/automated trading language for MetaTrader 5
Some experts please tell what is wrong with the below code, it is not counting the open orders?