Buba Akhrakhadze:
Hello everyone,
I am trying to count pending orders placed by an EA. There is a very odd result -134545644 or so. This function runs in OnTick() function. Can someone help to get the correct result? I've included the code below. Thanks!
You should set expertOrders to zero before you count.
Else it might have anything in it stored.
for(int i = 0; i <= ordersTotal - 1; i++){
If there are n orders, their indexes are [0 … n-1].

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
Hello everyone,
I am trying to count pending orders placed by an EA. There is a very odd result -134545644 or so. This function runs in OnTick() function. Can someone help to get the correct result? I've included the code below. Thanks!