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

Is there a way to catch order ignoring event from inside strategy code?

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

    Is there a way to catch order ignoring event from inside strategy code?

    Hello.

    Sometimes my orders ignored even is I checking GetCurrentAsk(), GetCurrentBid() and make distance in some ticks between market and order price:

    Strategy 'XXX': A Buy order placed at '1/17/2018 3:00:00 AM' has been ignored since the stop price is less than or equal to the close price of the current bar. This is an invalid order and subsequent orders may also be ignored. Please fix your strategy.
    Is there any way to catch "order ignored event" from inside strategy?

    (Right now I am using ``Unmanaged, but Managed is also interesting).
    fx.practic
    NinjaTrader Ecosystem Vendor - fx.practic

    #2
    Hello fx.practic,

    Thanks for your inquiry.

    I'd like to point out the following thread which discusses this with NT7: https://ninjatrader.com/support/foru...ad.php?t=41807

    We can typically work around this for realtime orders by setting RealtimeErrorHandling to IgnoreAllErrors or StopCancelCloseIgnoreRejects, and trapping the rejection in OnOrderUpdate(). For historical orders the strategy should be programmed to avoid submitting buy stop or buy stop limit orders below close of the current bar.

    RealtimeErrorHandling - https://ninjatrader.com/support/help...orhandling.htm

    One suggestion for historical orders would be to ensure order submission occurs at a valid price then to change it to the level you need at an appropriate time. Similar to the suggestion here.

    This is valid for both Managed and Unmanaged Strategies.

    Please let us know if we can be of further assistance.
    JimNinjaTrader Customer Service

    Comment


      #3
      Hello, Jim.
      This is my late "thank you"! )
      fx.practic
      NinjaTrader Ecosystem Vendor - fx.practic

      Comment

      Latest Posts

      Collapse

      Topics Statistics Last Post
      Started by Irukandji, Today, 04:58 AM
      0 responses
      2 views
      0 likes
      Last Post Irukandji  
      Started by fitspressoburnfat, Today, 04:25 AM
      0 responses
      2 views
      0 likes
      Last Post fitspressoburnfat  
      Started by Skifree, Today, 03:41 AM
      1 response
      4 views
      0 likes
      Last Post Skifree
      by Skifree
       
      Started by usazencort, Today, 01:16 AM
      0 responses
      1 view
      0 likes
      Last Post usazencort  
      Started by kaywai, 09-01-2023, 08:44 PM
      5 responses
      604 views
      0 likes
      Last Post NinjaTrader_Jason  
      Working...
      X