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

Can I Copy an Existing Strategy?

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

    Can I Copy an Existing Strategy?

    Hi,

    I am creating different strategies in NT7 that are somewhat similar to each other. Is it possible to copy a strategy as another name so that I can modify the new one? I don't want to delete the old one.

    I know that I can copy and paste different parts of the strategy but not the User Input Variables. I can't seem to find anywhere that addresses this issue so I am assuming that it can not be done. Can someone tell me if it is possible to copy a strategy?

    Thanks
    LarryRay

    #2
    One way to do this is by:

    Create a new strategy and give it to name that you want.

    Open the strategy you want to copy.

    Ctrl-A to select all text in the file.

    Ctrl-C to copy it.

    Switch to the new strategy file you created.

    Crtl-A to select all text in that file.

    Ctrl-V to replace it with the copied text of the other strategy.

    Now you have to change the "Name=" field to the name of the new strategy.

    Code:
    if (State == State.SetDefaults)
                {
                    Description                                    = @"";
                    Name                                        = "NameOfNewStrategy";
    That works in NT 8. It probably works in NT7 too.

    Comment


      #3
      Thanks

      Thank you so much for giving clear instructions on how I can do this. I will give it a try.

      Comment


        #4
        It's been a while in NT7, but when editing - right click and "SAVE AS".

        Comment

        Latest Posts

        Collapse

        Topics Statistics Last Post
        Started by cmtjoancolmenero, Yesterday, 03:58 PM
        11 responses
        39 views
        0 likes
        Last Post cmtjoancolmenero  
        Started by FrazMann, Today, 11:21 AM
        0 responses
        3 views
        0 likes
        Last Post FrazMann  
        Started by geddyisodin, Yesterday, 05:20 AM
        8 responses
        52 views
        0 likes
        Last Post NinjaTrader_Gaby  
        Started by DayTradingDEMON, Today, 09:28 AM
        4 responses
        26 views
        0 likes
        Last Post DayTradingDEMON  
        Started by George21, Today, 10:07 AM
        1 response
        22 views
        0 likes
        Last Post NinjaTrader_ChristopherJ  
        Working...
        X