if (PositionAccount.MarketPosition != MarketPosition.Flat)
{
Print("Bars since execution = " + BarsSinceEntryExecution());
}
Which gives the following in the output window.
Bars since execution = -1
Apparently -1 means there is no order, and yet -- there must be otherwise PositionAccount.Market would be equal to MarketPosition.Flat.
What am I missing?
Another clue is the trade window thinks I am flat too, though I see the entry on the chart.
Complete code attached. See line 167.
Thanks for the help!
Renaud

Comment