However, some trades start during trading times and do not end until well after end time. Specifically, at close; Exit on close = true.
Can someone explain why this is happening? Here's the code:
if (!bInTimeRange) // if within desired start/end times
{
ExitLong(); // not time to trade so exit if long
ExitShort(); // not time to trade so exit if short
}

Comment