Job finished
Specification
I have been developing an EA. I couldnt catch an event when pending order activated.
I just need a code to catch it and do something when a pending order triggered.
In the initial version of the program, I'm opening an instant active position. At the same time, I'm opening a pending order at a distance of distancePips. If this pending order is triggered, I want to open a new pending order at the same type at the location of the active position. I couldn't capture the triggering of this pending order. I need someone who can send me this code.
I tried to do it in OnTrade or OnTradeTransaction but couldn't find it.
first step
- Active buy position at 1123
- Pending sell order at 1023
---- its like a loop
-> when pending sell order triggered at 1023
-> open a new pending buy order at 1123
-> when pending buy order triggered at 1123
-> open a new pending sell order at 1023
----- i have to catch the triggering of pending order to do this !