Announcement

Collapse

Looking for a User App or Add-On built by the NinjaTrader community?

Visit NinjaTrader EcoSystem and our free User App Share!

Have a question for the NinjaScript developer community? Open a new thread in our NinjaScript File Sharing Discussion Forum!
See more
See less

Partner 728x90

Collapse

Name not show up on indicator list (compiled OK)

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

    Name not show up on indicator list (compiled OK)

    I convert Index indicator from NT7 to NT8, it compiled but name 'Index' won't show on indicator list.
    Attached Files

    #2
    Hello nkhoi,

    Thanks for your post.

    When a Ninjascript does not perform as expected please check the "log" tab for any related error messages.

    It is likely that the indicator is being prevented from being loaded due to an error in the OnStateChange() method and is being removed from the indicators list to prevent further potential issues.
    Paul H.NinjaTrader Customer Service

    Comment


      #3
      Originally posted by NinjaTrader_PaulH View Post
      Hello nkhoi,

      Thanks for your post.

      When a Ninjascript does not perform as expected please check the "log" tab for any related error messages.

      It is likely that the indicator is being prevented from being loaded due to an error in the OnStateChange() method and is being removed from the indicators list to prevent further potential issues.
      there is nothing on log tab after each compiling

      Click image for larger version

Name:	2018-12-03_1301.png
Views:	162
Size:	86.1 KB
ID:	1041622

      Comment


        #4
        Hello nkhoi,

        Thanks for your reply.

        I am not suggesting a compilation error as compilation errors would not show in the log tab, only in the Ninjascript editor window. A log tab type error would be generated from a "run time" type error where the previously compiled strategy is loaded/used/applied. Do you see any log errors when adding an (any) indicator to a chart?
        Paul H.NinjaTrader Customer Service

        Comment


          #5
          I added a indicator and I got error indicator 'Index' error on calling 'on state change' method. Object reference not set.

          Last edited by nkhoi; 12-03-2018, 03:17 PM.

          Comment


            #6
            Hello nkhoi,

            Thanks for your reply.

            You will need to debug your indicator named "Index" to determine what object has not been created when trying to access it.

            Please see our debug tips here: https://ninjatrader.com/support/help...script_cod.htm

            Taking a quick look at the code, it appears that you are trying to dynamically add data series which is not recommended in NinjaTrader 8. Please see the warning notes: https://ninjatrader.com/support/help...dataseries.htm There could be other issues but this was the first one observed.
            Paul H.NinjaTrader Customer Service

            Comment

            Latest Posts

            Collapse

            Topics Statistics Last Post
            Started by f.saeidi, Today, 11:02 AM
            1 response
            2 views
            0 likes
            Last Post NinjaTrader_BrandonH  
            Started by geotrades1, Today, 10:02 AM
            4 responses
            12 views
            0 likes
            Last Post geotrades1  
            Started by rajendrasubedi2023, Today, 09:50 AM
            3 responses
            16 views
            0 likes
            Last Post NinjaTrader_BrandonH  
            Started by lorem, Today, 09:18 AM
            2 responses
            11 views
            0 likes
            Last Post NinjaTrader_ChelseaB  
            Started by geddyisodin, Today, 05:20 AM
            4 responses
            30 views
            0 likes
            Last Post geddyisodin  
            Working...
            X