I have a strategy that runs on a chart with 2 symbols, but only trades the main symbol.
It has COBC = true and sends an entry order that remains active only for the next bar: MyEntryOrder = EnterLongStop(0, false, MyUnits_G, MyEntryPrice_G, MyEntryText);
Since the traded symbol can sometimes have no tick for several seconds I tried to cancel the order if the second symbol already completed the last bar where the entry was valid by using: CancelOrder(MyEntryOrder);
That doesn't work and the order only gets cancelled by timing out (no refresh on next bar).
Is it in general not possible to cancel the orders that expire after one bar? Or is there something wrong/missing in my code?
Thanks,
NutFlush



Comment