Hello good morning.
Thanks for reading me in advance!
I have a problem and I am not finding clear information or examples to solve my next problem for my strategy.
Before I closed my positions at the end of "X" hour with the order
ExitLong(6, @"END LONG", "");
Now I get 1 message "Where it is not possible to use ExitLong"
ninjatrader message:
Strategy 'XEL': Error on calling 'OnBarUpdate' method on bar 81077: Strategy 'XEL >> /251737744': Method 'ExitLong' can't be called on unmanaged strategies.
Thanks again for reading me...!!!
And sorry for the inconvenience, I hope someone can help me please.
if ((Times[0][0].TimeOfDay > HORA_END.TimeOfDay) && (TRADING_RUN_OFF == true)) { if (Position.MarketPosition == MarketPosition.Long) { ExitLong(6, @"END LONG", ""); } if (Position.MarketPosition == MarketPosition.Short) Print("SEARCH CODE"); TRADING_RUN_OFF = false; }
Comment