Completely new to writing strategies but have put something together that is working how i want for the most part.
The final issue's im contending with are that I want the strategy to perform as follows:
- If time[0] = x time then close any unfilled orders
- if time[0] = x time and an order is open then leave the associated stop loss and take profit orders open
Not sure if this is info you need to help but all orders in my strategy are set using SetProfitTarget, SetStopLoss, EnterLongLimit, and EnterShortLimit.
Additionally everything is currently done in onBarUpdate().
Sorry if this has been answered elsewhere but I couldnt find anything.
Thanks in Advance!

Comment