long deal_entry = HistoryDealGetInteger(deal_ticket, DEAL_ENTRY); if(deal_entry == DEAL_ENTRY_OUT) { // order is closed }
Ludovico Mattiuzzo:
I test and Trade window have 3 positions ... but I get 7 positions with:
if(deal_entry == DEAL_ENTRY_OUT)
?!
You are confusing Orders, Positions and Deals. Please go read the docs about it
Ludovico Mattiuzzo:
You are confusing Orders, Positions and Deals. Please go read the docs about it
You are confusing Orders, Positions and Deals. Please go read the docs about it
Yes... but:
Can I get code that list history positions like on MT5 (Toolbar - History) ..... with filter: 2days
??

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
Hi
With this we can see current orders and orders (positions) from history:
https://www.mql5.com/en/docs/trading/historyordergetticket
but I need to know which one are closed (MT5: __History View__) and wich are opened: MT5: __Trade View__
?!
BR
J.