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

Order not Executing

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

    Order not Executing

    Hey guys, I have an issue with my scaleout order not executing. Its on the Sim101 account.

    I have a strategy where there is a target, then once Close[0] gets above that target I send an order like:

    e=1;
    exitlongMACDScaling = ExitLong(e, "exitlongMACDScaling", "enterLongMACD1a");

    On the first pass, the order executes, then it resets the target to a higher level. Once the higher level hits, the next pass does not execute. Any idea why? There is a single entry, for say 5 contracts with the order name enterLongMACD1a.

    I also have print statements surrounding the above order and they both work fine.

    Thanks,
    EliteTraderNYC

    #2
    Hello EliteTraderNYC,

    Thank you for your note.

    Are you setting exitlongMACDScaling to null when it has filled? If not, please do so and advise if this resolves the matter.
    Code:
    protected override void OnOrderUpdate(IOrder order)
    {
        if (exitlongMACDScaling != null && exitlongMACDScaling == order)
        {
            if (order.OrderState == OrderState.Cancelled)
             {
                  exitlongMACDScaling = null;
             }
        }
    }

    Comment


      #3
      Hi sir, unfortunately this did not solve the problem. I also tried Order status filled and that did not work. Any other ideas?

      Comment


        #4
        Hello EliteTraderNYC,

        Thank you for your response.

        Do you have a test script or may I test your full strategy on my end?

        Comment


          #5
          Hi, yes what is your email?

          Comment


            #6
            Hell elitetradernyc,

            Thanks for your reply.

            Please email support[at]ninjatrader[dot]com you test script. In the message put ATTN Patrick and include a link to this forum topic.
            BrandonNinjaTrader Customer Service

            Comment


              #7
              Originally posted by elitetradernyc View Post
              Hi sir, unfortunately this did not solve the problem. I also tried Order status filled and that did not work. Any other ideas?
              So you made a single entry order and are trying to scale out in exits?

              Comment


                #8
                Yes thats right, support staff tells me i need to create different order names for the scaleout sells.

                Comment


                  #9
                  Originally posted by elitetradernyc View Post
                  Yes thats right, support staff tells me i need to create different order names for the scaleout sells.
                  No can do, period in NT7. This is a bug that NT has already acknowledged, but will not fix in the current iteration.

                  More information is in this single post: http://www.ninjatrader.com/support/f...d.php?p=371491

                  It is part of two pretty long discussions which show that, in NT7, one cannot scale out without scaling in.

                  Comment

                  Latest Posts

                  Collapse

                  Topics Statistics Last Post
                  Started by warreng86, 11-10-2020, 02:04 PM
                  6 responses
                  1,359 views
                  0 likes
                  Last Post mathewlo  
                  Started by Perr0Grande, Today, 08:16 PM
                  0 responses
                  5 views
                  0 likes
                  Last Post Perr0Grande  
                  Started by elderan, Today, 08:03 PM
                  0 responses
                  9 views
                  0 likes
                  Last Post elderan
                  by elderan
                   
                  Started by algospoke, Today, 06:40 PM
                  0 responses
                  10 views
                  0 likes
                  Last Post algospoke  
                  Started by maybeimnotrader, Today, 05:46 PM
                  0 responses
                  14 views
                  0 likes
                  Last Post maybeimnotrader  
                  Working...
                  X