I saw "MQL4.com is moving to MQL5.com." However can't find the forum related MQL4.
Please let me ask the questions of MQL4 here.
Let's say there are many loops of orders, each loop follows previous loop. In every loop, there are a series of orders and a whole loop means the series of orders are all closed based on a condition.
In order to recover the tracking once EA/terminal/PC is restarted while a loop is still ongoing, need select every order in this loop correctly. However, some orders are still open and some are closed already.
Once EA is restarted, only total orders in the ongoing loop can be retrieved, that is "ArrOrderSize" in the codes below. However, how to select the orders correctly now that some are still open and some are closed?
MQL4 questions are AOK here :)
Without seeing your full code and understanding what ArrOrderSize is, are you using OrdersTotal()
MQL4 questions are AOK here :)
Without seeing your full code and understanding what ArrOrderSize is, are you using OrdersTotal()
Dear Filter, please try to understand what I want to ask and no need more codes here indeed.
"Once EA is restarted, only total orders,'ArrOrderSize', in the ongoing loop can be retrieved"
I saw "MQL4.com is moving to MQL5.com." However can't find the forum related MQL4.
Please let me ask the questions of MQL4 here.
Let's say there are many loops of orders, each loop follows previous loop. In every loop, there are a series of orders and a whole loop means the series of orders are all closed based on a condition.
In order to recover the tracking once EA/terminal/PC is restarted while a loop is still ongoing, need select every order in this loop correctly. However, some orders are still open and some are closed already.
Once EA is restarted, only total orders in the ongoing loop can be retrieved, that is "ArrOrderSize" in the codes below. However, how to select the orders correctly now that some are still open and some are closed?
Check MQL4 book examples on Closing and deleting orders and Order Accounting
This is tutorial style text with documented code examples.
- book.mql4.com
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
You agree to website policy and terms of use
I saw "MQL4.com is moving to MQL5.com." However can't find the forum related MQL4.
Please let me ask the questions of MQL4 here.
Let's say there are many loops of orders, each loop follows previous loop. In every loop, there are a series of orders and a whole loop means the series of orders are all closed based on a condition.
In order to recover the tracking once EA/terminal/PC is restarted while a loop is still ongoing, need select every order in this loop correctly. However, some orders are still open and some are closed already.
Once EA is restarted, only total orders in the ongoing loop can be retrieved, that is "ArrOrderSize" in the codes below. However, how to select the orders correctly now that some are still open and some are closed?