Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

CalculateOnBarClose

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

    CalculateOnBarClose

    In my strategy, there are things I need to calculate every tick and also things I need to do only on bar close. If I set CalculateOnBarClose = false so that OnBarUpdate( ) will be called every tick then how can I determine the bar close condition?

    #2
    Originally posted by kojava View Post
    In my strategy, there are things I need to calculate every tick and also things I need to do only on bar close. If I set CalculateOnBarClose = false so that OnBarUpdate( ) will be called every tick then how can I determine the bar close condition?
    Code:
    if (FirstTickOfBar)
    {
    // handle stuff on the last bar, ie, Close[1], High[1], or whatever, but on bar index 1
    }

    Comment


      #3
      Welcome to our forums kojava - for a dedicated sample on this topic, you can check into this link :

      BertrandNinjaTrader Customer Service

      Comment

      Latest Posts

      Collapse

      Topics Statistics Last Post
      Started by rtwave, 04-12-2024, 09:30 AM
      2 responses
      20 views
      0 likes
      Last Post rtwave
      by rtwave
       
      Started by tsantospinto, 04-12-2024, 07:04 PM
      5 responses
      67 views
      0 likes
      Last Post tsantospinto  
      Started by cre8able, Today, 03:20 PM
      0 responses
      6 views
      0 likes
      Last Post cre8able  
      Started by Fran888, 02-16-2024, 10:48 AM
      3 responses
      49 views
      0 likes
      Last Post Sam2515
      by Sam2515
       
      Started by martin70, 03-24-2023, 04:58 AM
      15 responses
      115 views
      0 likes
      Last Post NinjaTrader_Jesse  
      Working...
      X