• If this is your first visit, you will have to register before you can post. To view messages, please scroll below and select the forum that you would like to visits. Questions? Be sure to check out the Forum FAQ.

Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Loading previous strategy list

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

    Loading previous strategy list

    In the Control Center on the Strategies tab, after I add a series of strategies there is a "Save As..." option. I save my defined strategies.

    So how do I load these strategies again? I just see a "Save As..." but no "Load" or "Import". What's the point?

    #2
    "Save as" is a standard option for every grid and saves the grid content to a file.

    Please learn more here on NT grids: http://www.ninjatrader-support.com/H...Overview3.html
    DierkNinjaTrader Customer Service

    Comment


      #3
      Originally posted by NinjaTrader_Dierk View Post
      "Save as" is a standard option for every grid and saves the grid content to a file.

      Please learn more here on NT grids: http://www.ninjatrader-support.com/H...Overview3.html
      Who would ever want to save a list of strategies if they can't re-load it?

      It's a time-consuming and error-prone task to add all of my strategies (since I have to do it for each, individual instrument, ugh). Is there any way that I can save the list and then load it again?

      Comment


        #4
        Not sure I follow. Please consult the link below: "Save as" only saves the text content of a grid to a file, nothing more and nothing less.

        >> Is there any way that I can save the list and then load it again?
        Unfortunately this is not supported at this time.
        DierkNinjaTrader Customer Service

        Comment


          #5
          'Cause this is a very important issue to me, I wrote an AutoIt script which will automate/hijack the NinjaTrader UI to add a list strategies. It's extremely user un-friendly, intolerant of glitches and isn't easily extensible but it works for me. I'm reluctant to do more work on it since I'm hoping that version 7.0 will offer real support for this feature. (hint hint )

          As a safety precaution, the script is provided without documentation, tips or pointers. If you can't install AutoIt on your own and successfully modify the source code, then it's probably too raw for you anyway.

          Enjoy

          Code:
          ; run the script then click the 'Strategies' window of NinjaTrader
          
          WinWaitActive("Control Center - Default")
          
          Dim $anArray[4]
          
          $anArray[0]="AAPL"
          $anArray[1]="AMZN"
          $anArray[2]="BIDU"
          $anArray[3]="EOG"
          
          for $element in $anArray
              AddStrategy( "MyStrategy", $element )
          NEXT
          
          
          Func AddStrategy($stratName, $ticker)
          
              MouseClick("right")
              Sleep(100)
              Send("N")
              
              Dim $currStrat
              $currStrat = WinGetText("New Strategy")
              While StringInStr( $currStrat, $stratName) == 0
                  Send( StringLeft($stratName, 1) )
                  Sleep(1000)
                  $currStrat = WinGetText("New Strategy")
              Wend
          
              ; Get the instrument field
              ControlClick("New Strategy", "", "[CLASS:WindowsForms10.Window.8.app.0.378734a; INSTANCE:4]", "left", 1, 235, 56)
              Sleep(1000)
              ControlClick("New Strategy", "", "[CLASS:WindowsForms10.BUTTON.app.0.378734a; INSTANCE:3]", "left", 1, 7, 7)
              Sleep(1000)
              ControlFocus("New Strategy", "", "[CLASS:WindowsForms10.Window.8.app.0.378734a, INSTANCE:2]")
              Sleep(1000)
              
              Dim $sel = WinGetText("")
              If StringInStr( $sel, "<Default>" ) <> 0 Then
                  Send("S")
                  Sleep(1000)
              EndIf
              
              Send($ticker & "{ENTER}")
              Sleep(1000)
              Send("{ENTER}")
              Sleep(1000)
          EndFunc
          Last edited by adrian; 04-15-2008, 04:33 PM.

          Comment

          Latest Posts

          Collapse

          Topics Statistics Last Post
          Started by rontronimous, Today, 06:12 PM
          1 response
          3 views
          0 likes
          Last Post NinjaTrader_ShawnB  
          Started by Vinhasa, Today, 03:15 PM
          3 responses
          13 views
          0 likes
          Last Post NinjaTrader_Manfred  
          Started by 1001111, Today, 03:03 PM
          1 response
          8 views
          0 likes
          Last Post NinjaTrader_Tyler  
          Started by Seedbird, Today, 03:06 PM
          1 response
          12 views
          0 likes
          Last Post NinjaTrader_BrendanC  
          Started by mtamaku, Today, 02:46 PM
          1 response
          6 views
          0 likes
          Last Post NinjaTrader_Kate  
          Working...
          X