Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Changing onbarclose after stratetgy start

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

    Changing onbarclose after stratetgy start

    Can you change on onbarclose midstream on a strategy? I need to see the first few ticks to establish some initialization code then I would like to change it back to OnBarClose=false to save resources. I didn't know if once established if you can change it or not or if it would be ignored.

    #2
    Hello ct,

    You can change strategy parameters settings of automated strategies in NinjaTrader 7. However you will need to disable the strategy first - you cannot change strategy parameters while the strategy is running.

    Please note that setting 'Calculate on bar close' to False will take more resources than setting it to True.

    Comment


      #3
      Jason

      so from within the strategy I cannot change the setting of on barclose?

      Comment


        #4
        You can change 'Calculate on bar close' within the strategy code as well.

        Comment


          #5
          Jason

          Will the strategy will be re-initialized when I do this? Or simply not receive the next tick until on barclose?

          Cliff

          Comment


            #6
            You will need to compile your strategy after making the change in the strategy code and the change will be effective.

            Comment

            Latest Posts

            Collapse

            Topics Statistics Last Post
            Started by Geovanny Suaza, 02-11-2026, 06:32 PM
            0 responses
            599 views
            0 likes
            Last Post Geovanny Suaza  
            Started by Geovanny Suaza, 02-11-2026, 05:51 PM
            0 responses
            344 views
            1 like
            Last Post Geovanny Suaza  
            Started by Mindset, 02-09-2026, 11:44 AM
            0 responses
            103 views
            0 likes
            Last Post Mindset
            by Mindset
             
            Started by Geovanny Suaza, 02-02-2026, 12:30 PM
            0 responses
            558 views
            1 like
            Last Post Geovanny Suaza  
            Started by RFrosty, 01-28-2026, 06:49 PM
            0 responses
            557 views
            1 like
            Last Post RFrosty
            by RFrosty
             
            Working...
            X