Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Rejected Order Handling

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

    Rejected Order Handling

    Hello Support,

    I am testing my Strategy live, and twice the pop-up dialog box appears when the market quickly turns and hit the Stop order on the DOM. It says the strategy submit an order that is rejected and terminated itself.

    How can I put in codes that would allow the strategy to:
    1. Continue running, and hence be able to
    2. Resubmit, persummably a modified stop order.

    I am already using OnOrderUpdate, and it handles multiple entries and exit signals.

    Thanks.

    Regards.

    EdwardK.

    #2
    Hi Edward, you would need to turn off the default error handling to handle it yourself -

    Comment


      #3
      Hello Support,

      Perhaps it would be clearer if I describe the highlighted Log here:

      11:05:32 Order TE_invalidBuyStopPrce Affected Order: BuyToCover 1 [email protected]

      11:05:32 Strategy Strategy name submitted an order that generated the following error "UnableToChangeOrder". Strategy has sent cancel requests, attempted to close the position and terminated itself.

      11:05:33 Order GTCs must be submitted as limit or stop limit orders. Affected Order: BuyToCover 1 Market

      11:05:33 Strategy Strategy name submitted an order that generated the following error "OrderRejected". Strategy has sent cancel requests, attempted to close the position and terminated itself.

      This happens when the market hit and exceed the stop ultra quickly. Normal speed does not cause this issue.
      Kindly let me know your advise on how to handle this ?


      Thanks.
      Regards,
      EdwardK.

      Comment


        #4
        Likely this would mean you need to work with a different TIF setting for your strategy - which exchange / product are you trading? TF? Would you mind sendming me full logs / trace to support at ninjatrader dot com for review?

        Thanks

        Comment


          #5
          Hello Bertrand,

          Yes, the instrument is TF. There is no other highlights on the Log.
          Why is that normally the stop works fine and only become a problem when the market moves fast past the stop ?
          So would TIF setting of Day solve the issue ?
          Also Stops are Market order, do I need to use Stop Limit orders along with TIF = Day ?

          Thanks.

          Regards.
          EdwardK

          Comment


            #6
            Thanks Edward, I would not know why you get the TIF error then, as I would normally expect just the stop getting rejected then due to incorrect price being used - perhaps it would be best if you check with your broker with TIF they recommend using on the TF for your setup.

            Comment


              #7
              Hello Bertrand,

              My broker is ZenFire/Dorman. Would you know the solution?

              I notice Target is a limit order and its state is Working, ie. it is on the exchange. I never get Target filling issue, though I might get a better price when market moves fast past it.

              But the TrailStop is market order and its state is Accepted, ie. it is just with the broker.

              Is there anyway to get the trail Stop as Working order as a "Market If Touch" or "StopLimit" order ?

              I just wonder what is the cause, why is there a InvalidBuyStop price when it is a market order. By definition market order guarantee delivery but not the price.

              Thanks.
              Regards,
              EdwardK

              Comment


                #8
                You would just need to submit the order as a stop-limit order and custom program your own trailing logic if you want it to trail. Set() method is a stop-market order.
                Josh P.NinjaTrader Customer Service

                Comment


                  #9
                  Hello Josh,

                  That would need me to get the OCO token when Target order is updated, but how do I submit StopLimit Order with OCO setting ?

                  Can NT update the SetTrailStop with ordertype parameter? It could be vastly simpler at your end.

                  Thanks.
                  BestRegards,
                  Edward.

                  Comment


                    #10
                    Thanks for the suggestion Edward - if you need it OCO'ed you would need to program this yourself by checking the fillstates and CancelOrder the other part of the bracket if needed.

                    Comment

                    Latest Posts

                    Collapse

                    Topics Statistics Last Post
                    Started by Geovanny Suaza, 02-11-2026, 06:32 PM
                    0 responses
                    649 views
                    0 likes
                    Last Post Geovanny Suaza  
                    Started by Geovanny Suaza, 02-11-2026, 05:51 PM
                    0 responses
                    370 views
                    1 like
                    Last Post Geovanny Suaza  
                    Started by Mindset, 02-09-2026, 11:44 AM
                    0 responses
                    109 views
                    0 likes
                    Last Post Mindset
                    by Mindset
                     
                    Started by Geovanny Suaza, 02-02-2026, 12:30 PM
                    0 responses
                    574 views
                    1 like
                    Last Post Geovanny Suaza  
                    Started by RFrosty, 01-28-2026, 06:49 PM
                    0 responses
                    576 views
                    1 like
                    Last Post RFrosty
                    by RFrosty
                     
                    Working...
                    X