Theoretical question about order pool MOD_TRADES
We can look for a specific magic number by looping through MOD_TRADES.
But what happens to that loop when you decide to delete or close one of the active tickets? Let’s say we have 5 pending orders: A to E. What happens if we decide to delete order C from within that loop? Does D become the third order in the loop or does it stay in fourth place?
D*mn... why didn't I think of that? The answer is so logical :-)
I tried looking for such a posting, but wasn't able to find it. Thanks Raptor, that explains everything. Now I have to go through all my code to see where I did it wrong ;-\
We can look for a specific magic number by looping through MOD_TRADES.
But what happens to that loop when you decide to delete or close one of the active tickets? Let’s say we have 5 pending orders: A to E. What happens if we decide to delete order C from within that loop? Does D become the third order in the loop or does it stay in fourth place?