Objective.
Limit orders are submitted when conditional statements are met and said limit order is attached to an indicator which moves the limit order placement along with it. Once price hits that indicator the limit order is filled. The limit order is deliberately being kept alive until this occurs.
As of 2 PM Chicago time, if any unfilled limit orders are still outstanding, they need to be cancelled. So:
// Kill Open Limit orders if exist at 2.00 PM Chicago time
if
(Times[0][0].TimeOfDay = End_Time.TimeOfDay) // User Interface Time Value set to 2PM
{
CancelOrder(Order "Long");
CancelOrder(Order "Short");
}
The limit order names are simply either Long or Short. I know above is incorrect. Not understanding the help guide explanation.

Comment