I have a problem with sequence of actions in NinjaTrader. In my sample strategy I'm opening a Long position. If it reaches a max daily loss, position is forcefully closed.
But if the market moves very quickly, ExitLong isn't handled properly. On Output I'm getting couple of messages "MaxDailyLoss" even though ExitLong should be triggered after the first message. Then market hits a StopLoss and position is closed.
After StopLoss closes the position, ExitLong is executed and strategy gets over filled.
Why in strategy with CalculateOnBarClose = false the ExitLong doesn't close position before it hits StopLoss, when market moves very quickly (about 20 ticks in 1 second)?
I've attached my sample strategy code (part of my bigger strategy).


Comment