Cbi.Position myPosition = Account.Positions.FindByInstrument(Instrument);
To get some semblance of real (ie actual) portfolio level tracking into NT. Now I am at another barrier.
I believe that Position.MarketPosition is used internally by NinjaScript to decide if there is or is not a position to "Exit" when using ExitLong, for example.
This mean that although my code is now much more successful at traking the portfolio, all of the Exit commands are not working because internally NinjaScript thinks there is no position when in fact there is.
How can I use "Exit" commands when
Position.MarketPosition == MarketPosition.Flat
But in fact a position exists?
Comment