Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Strategy not recognized when trying to add

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

    Strategy not recognized when trying to add

    I have a Ninjascript/ATM multi time frame strategy that I cannot add to the strategies tab in the control center. When I bring up the add new strategy window it always adds the previously selected strategy. When I use the arrow keys to scroll between strategies none of the information changes when I get to this particular strategy (variables/dataseries info). I had originally created this strategy by using the save as function to save/rename this one.

    Once I encountered this error I copied and pasted the entire script into a new blank document, and changed all the instances of the old strategy name within but still haven't had any luck. Maybe I missed a reference to the old strategy name somewhere?

    #2
    Hello MisterGee,

    Thank you for writing in.

    Once you have made changes to your strategy, have you compiled the code? You will need to compile the code once you have made any changes to the strategy for the changes to take effect.
    Zachary G.NinjaTrader Customer Service

    Comment


      #3
      Yes, multiple times.

      Comment


        #4
        Hello MisterGee,

        Please export your strategy so I may test on my end.

        To export your script do the following:
        1. Click File -> Utilities -> Export NinjaScript
        2. Enter a unique name for the file in the value for 'File name:'
        3. Select the strategy from the objects list on the left -> click the right facing arrow ">" to add the strategy to the export
        4. Click the 'Export' button -> click 'yes' to add any referenced indicators to the export -> click OK to clear the export location message


        By default your exported file will be in the following location:
        • (My) Documents/NinjaTrader 7/bin/Custom/ExportNinjaScript/<export_file_name.zip>


        Below is a link to the help guide on Exporting NinjaScripts.
        http://www.ninjatrader.com/support/h...nt7/export.htm
        Zachary G.NinjaTrader Customer Service

        Comment


          #5
          Here is a .zip of the strategy
          Attached Files

          Comment


            #6
            Originally posted by MisterGee View Post
            Here is a .zip of the strategy
            Nice work!

            I see the same issue here. It added another strategy, not TrendTraderDeluxe!!!

            nt 7.0.1000.27...

            Comment


              #7
              Originally posted by MisterGee View Post
              Here is a .zip of the strategy
              Geezus... I created a new strategy, with a new name, and pasted in everything but onbarupdate - and same thing..even restarted NT.

              Are you on the latest Nt 7? (.31)???

              Comment


                #8
                Originally posted by MisterGee View Post
                Here is a .zip of the strategy
                Turn on the Output Window and you will see the errors.


                "Failed to call method 'Initialize' for strategy 'TreadTraderDeluxe.........'......



                You can't do that in there!!!

                Comment


                  #9
                  Originally posted by MisterGee View Post
                  I have a Ninjascript/ATM multi time frame strategy that I cannot add to the strategies tab in the control center. When I bring up the add new strategy window it always adds the previously selected strategy. When I use the arrow keys to scroll between strategies none of the information changes when I get to this particular strategy (variables/dataseries info). I had originally created this strategy by using the save as function to save/rename this one.

                  Once I encountered this error I copied and pasted the entire script into a new blank document, and changed all the instances of the old strategy name within but still haven't had any luck. Maybe I missed a reference to the old strategy name somewhere?
                  That almost always means that there is a NT processing error in the strategy. What is the error in your log and/or Output Window?
                  Last edited by koganam; 03-14-2016, 07:21 AM.

                  Comment


                    #10
                    Variable definition does not go in the Initialize() method. Changing this, I can now select the strategy in the control center.

                    Comment


                      #11
                      Now when I run the strategy on market replay it'll execute a few trades then throw an error

                      'Error on calling onbarupdate method: index was outside the bounds of the array'

                      Comment


                        #12
                        Any more NT support staff have input????

                        Comment


                          #13
                          Hello MisterGee,

                          Thank you for your post.

                          Can you respond with your updated strategy attached to the post?

                          Comment


                            #14
                            I had to comment or remove any instance of my variable as that seems to be the problem now. I'm not real familiar with double variables, and especially not in the capacity in trying to use it.
                            Attached Files

                            Comment


                              #15
                              Resolved

                              I figured it out on my own. Thanks.

                              Comment

                              Latest Posts

                              Collapse

                              Topics Statistics Last Post
                              Started by Segwin, 05-07-2018, 02:15 PM
                              10 responses
                              1,769 views
                              0 likes
                              Last Post Leafcutter  
                              Started by Rapine Heihei, 04-23-2024, 07:51 PM
                              2 responses
                              30 views
                              0 likes
                              Last Post Max238
                              by Max238
                               
                              Started by Shansen, 08-30-2019, 10:18 PM
                              24 responses
                              943 views
                              0 likes
                              Last Post spwizard  
                              Started by Max238, Today, 01:28 AM
                              0 responses
                              10 views
                              0 likes
                              Last Post Max238
                              by Max238
                               
                              Started by rocketman7, Today, 01:00 AM
                              0 responses
                              7 views
                              0 likes
                              Last Post rocketman7  
                              Working...
                              X