Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Using AdoptAccountPosition

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Using AdoptAccountPosition

    I created a multi-Instrument strategy and I don't need ninjatrader do any historical processing on a strategy. I just need it adopt the current account positions and continue.


    I set
    IsAdoptAccountPositionAware = true;
    StartBehavior = StartBehavior.AdoptAccountPosition;

    I use a simulator account. Every time I restart the strategy all positions reset to zero. What can I do to prevent this?
    Last edited by ManTrader; 07-09-2019, 01:25 PM.

    #2
    Hello ManTrader,

    Thank you for your post.

    To clarify, the behavior is that you have a manually placed order, and despite being set to IsAdoptAccountPositionAware = true and StartBehavior = StartBehavior.AdoptAccountPosition, all orders are being closed instead of adopted as the strategy position, is that correct?

    Could you explain further how you are checking for the account position when the strategy is enabled? If you have a reduced version of your strategy (you can remove all code not necessary to reproduce the behavior) that would be very helpful.

    Thanks in advance; I look forward to assisting you further.

    Comment


      #3
      Sorry, I was testing with Playback account! Simulate account is working correctly. You can remove this issue.

      Comment

      Latest Posts

      Collapse

      Topics Statistics Last Post
      Started by CaptainJack, 05-29-2026, 05:09 AM
      0 responses
      475 views
      0 likes
      Last Post CaptainJack  
      Started by CaptainJack, 05-29-2026, 12:02 AM
      0 responses
      315 views
      0 likes
      Last Post CaptainJack  
      Started by charlesugo_1, 05-26-2026, 05:03 PM
      0 responses
      253 views
      1 like
      Last Post charlesugo_1  
      Started by DannyP96, 05-18-2026, 02:38 PM
      1 response
      340 views
      0 likes
      Last Post NinjaTrader_ChelseaB  
      Started by CarlTrading, 05-11-2026, 05:56 AM
      0 responses
      305 views
      0 likes
      Last Post CarlTrading  
      Working...
      X