Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Session Templates?

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

    Session Templates?

    My indicator gets the following error:

    "Time Category Message - Error on calling 'OnStateChange' method: 'AddDataSeries' method only accepts valid trading hours names, but 'Default 24x7' does not exist in the Trading Hours Manager."

    REALLY? ;-)

    #2
    Hello molecool,

    Thank you for writing in.

    Did you create this NinjaScript Strategy/Indicator yourself?

    Or, did you get this NinjaScript Strategy/Indicator from a 3rd party Developer?

    Finally, if you go to a Chart and select the "Default 24x7" trading hours template and click OK, does an error appear?
    Clayton G.NinjaTrader Customer Service

    Comment


      #3
      Nah I wrote it myself - and I made sure that Default 24x7 worked in the chart (BTCUSD).

      So I eventually got it compiled by using Bars.TradingHours.Name which worked. You may want to document the session strings though somewhere, I only found the attribute by accident.

      Comment


        #4
        Hello molecool,

        Capitalization and spaces matter in matching strings.

        Try "Default 24 x 7"

        You can view the exact name in the Tools -> Trading Hours window. These strings are subject to change by the user.
        Chelsea B.NinjaTrader Customer Service

        Comment

        Latest Posts

        Collapse

        Topics Statistics Last Post
        Started by Jonafare, 12-06-2012, 03:48 PM
        5 responses
        3,984 views
        0 likes
        Last Post rene69851  
        Started by Fitspressorest, Today, 01:38 PM
        0 responses
        2 views
        0 likes
        Last Post Fitspressorest  
        Started by Jonker, Today, 01:19 PM
        0 responses
        2 views
        0 likes
        Last Post Jonker
        by Jonker
         
        Started by futtrader, Today, 01:16 PM
        0 responses
        7 views
        0 likes
        Last Post futtrader  
        Started by Segwin, 05-07-2018, 02:15 PM
        14 responses
        1,791 views
        0 likes
        Last Post aligator  
        Working...
        X