Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Using a trading hour template within indicator script

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

    Using a trading hour template within indicator script

    Hi there,

    I'm hoping I can call a trading hour template within an indicator script such as the "CME US Index Futures RTH" trading hour template.

    So that the indicator uses the trading hour template hours for its calculations.

    I want to do this so that I can apply this indicator to a chart thats using "instrument settings", but the indicator is using the CME US Index Futures RTH​ trading hour template.

    Is this possible?

    Any help will be much appreciated


    #2
    Hello RoswellTrader,

    You can add a data series and specify the trading hours.

    AddDataSeries(string instrumentName, BarsPeriod barsPeriod, string tradingHoursName)
    https://ninjatrader.com/support/help...dataseries.htm

    Then you can perform the logic during the BarsInProgress for that series. (If there is only 1 added series this would be during BarsInProgress 1)
    Chelsea B.NinjaTrader Customer Service

    Comment


      #3
      Thank you Chelsea, this worked perfectly! Much appreciated

      Comment

      Latest Posts

      Collapse

      Topics Statistics Last Post
      Started by CarlTrading, 03-31-2026, 09:41 PM
      1 response
      46 views
      0 likes
      Last Post NinjaTrader_ChelseaB  
      Started by CarlTrading, 04-01-2026, 02:41 AM
      0 responses
      22 views
      0 likes
      Last Post CarlTrading  
      Started by CaptainJack, 03-31-2026, 11:44 PM
      0 responses
      33 views
      1 like
      Last Post CaptainJack  
      Started by CarlTrading, 03-30-2026, 11:51 AM
      0 responses
      50 views
      0 likes
      Last Post CarlTrading  
      Started by CarlTrading, 03-30-2026, 11:48 AM
      0 responses
      42 views
      0 likes
      Last Post CarlTrading  
      Working...
      X