Hi,
Maybe this can help you, just read the deal history and filter by OUT deals, then just read the deal time.
#include <Trade\OrderInfo.mqh> #include <Trade\DealInfo.mqh> ... COrderInfo orderInfo; CDealInfo dealInfo; ... HistorySelect(0,TimeCurrent()); for(int pos=HistoryDealsTotal()-1; pos>=0; pos--) { if(dealInfo.SelectByIndex(pos)) { // Read deal out and get deal time if(dealInfo.Entry()==DEAL_ENTRY_OUT && dealInfo.Symbol()==Symbol()) { datetime close_time = dealInfo.Time(); } } }

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
i want time close order.
thank you.