Is it possible to pause the timer.
It looks like EventTimeKiller(); only works with DeInit.
I would like to pause the timer while I execute some orders and then restart the timer once I have finished executing my orders.
What makes you think that it only works from OnDeInit?
I think that I have spotted the problem.
Afetr EventTimKiller(), I close all pending orders, but without having a sleep between each orderd to close. The loop then ends and the EventSetTimer() is triggered, but straight away, as all orders are not closed, it stops again, closes what's left...
I will add a sleep between each order to close and see if that solves the problem.