At the beginning of OnBarUpdate()
- I have an IOrder long = EnterLongStop that (as of the previous bar) has OrderState = Working
- I call CancelOrder(long)
- Later in the same OnBarUpdate() I call IOrder short = EnterShortStop(...)
This sequence produces the following error for the EnterShortStop attempt:
Is there a workaround for this so that I can cancel a pending stop order and enter a new one in the same OnBarUpdate()?
Comment