I've searched the forum but didn't find any topic relevant to my question so here goes.
Is there a way in MQL4 to check how long a pending order has been sitting in the system and has not been executed?
This is more of a sanity check for me to verify the expiration time set for pending order is correctly honoured which I have doubt on and so I can gather evidence to take back to my broker.
Thanks in advance.
I'm fairly certain that OrderOpenTime() does not work with pending orders.
What you could do is cycle through your orders and see if TimeCurrent() > OrderExpiration()
To add comments, please log in or register