15. 3. 2023

5 5

Closed P/L from specific hour (in money)

Closed P/L from specific hour

 

Implemented in MT4/MT5.

 

More details will added soon.

Subscribe
Notify of
5 Comments
Oldest
Newest Most Voted
Inline Feedbacks
View all comments
Emmanuel
16. 3. 2023 9:05 am

Good Idea !! Thank you Ivan

Emmanuel
21. 9. 2023 8:22 am

Very interesting , however the ORDER_TIME_DONE constant will give an open time of the order I think.
I don’t think we have a closing time of an order in MQL5 , have we ?

Emmanuel
Reply to  Emmanuel
21. 9. 2023 9:03 am

we need to make sure , it is a closing deal , an Out deal .

with HistoryDealGetInteger(deal_ticket, DEAL_ENTRY) == DEAL_ENTRY_OUT) ??

Emmanuel
Reply to  Emmanuel
21. 9. 2023 9:20 am

We have the Profit, and we need to include, commission cost and swap cost :
sumPL += HistoryDealGetDouble(ticket, DEAL_PROFIT) + HistoryDealGetDouble(ticket, DEAL_COMMISSION) + HistoryDealGetDouble(ticket, DEAL_SWAP);
Do we ?

Emmanuel
21. 9. 2023 9:22 am

as the profit = 0 on opening deal, the ORDER_TIME_DONE will work on closing deal