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

Range and minutes

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

    Range and minutes

    I have a strategy in a minute chart and I want to add a "range" bar with Add(PeriodType.Range...).

    I insert the strategy in minute chart but I want that the strategiy acct in the range bar (with BarsInProgress == 1).

    But when I insert the strategy in the minute chart, I don't obtain that the strategy buy or sell.

    It's possible to make this?

    Thanks.

    #2
    Hello soyjesus,

    If you want to submit orders to the other series, you must use the enter methods that allow submitting to a specific BarsInProgress.


    EnterLong(int barsInProgressIndex, int quantity,string signalName)
    Ryan M.NinjaTrader Customer Service

    Comment


      #3
      Ok Ryan_M, thank you very much for your help. Now I have a new problem. When the time frame in range send a order (buy or sell) it is automaticly cancelled. Why?

      Thanks in advance.

      Jesus.

      Comment


        #4
        Hello Jesus,

        Can you clarify what you mean by automaticaly cancelled?

        Unless you're using liveUntilCanceled = true, then orders are cancelled if they are not filled on the bar they're submitted to. Is this what you're seeing?
        Ryan M.NinjaTrader Customer Service

        Comment


          #5
          I'm using liveUntilCanceled = false, but when the order is trigered (from time frame in range), a new order cancelling is sent inmediately.

          Comment


            #6
            Soyjesus,

            Use TraceOrders output to track what's going on here. In the Initialize() method, add TraceOrders = true; You can then view output through tools > output window.

            If you're running into issues, share your output along with the code that is submitting orders.
            Ryan M.NinjaTrader Customer Service

            Comment

            Latest Posts

            Collapse

            Topics Statistics Last Post
            Started by trilliantrader, 04-18-2024, 08:16 AM
            5 responses
            22 views
            0 likes
            Last Post trilliantrader  
            Started by Davidtowleii, Today, 12:15 AM
            0 responses
            3 views
            0 likes
            Last Post Davidtowleii  
            Started by guillembm, Yesterday, 11:25 AM
            2 responses
            9 views
            0 likes
            Last Post guillembm  
            Started by junkone, 04-21-2024, 07:17 AM
            9 responses
            68 views
            0 likes
            Last Post jeronymite  
            Started by mgco4you, Yesterday, 09:46 PM
            1 response
            12 views
            0 likes
            Last Post NinjaTrader_Manfred  
            Working...
            X