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

Cancel pending order once one executes.

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

    Cancel pending order once one executes.

    I am having problems cancelling an order once one executes. How would you approach this problem?

    OnBarClose()
    Enter ATM with BUY STOP
    Enter ATM with SELL STOP
    ( Of course the only way to do this is with two different ATM Strategies , I have no problem here) basically a straddle of the candle. One at The HIGH and one at The LOW.)

    Now once one of the orders executes , I need to cancel the other immediately , and not wait until the bar closes.

    Any suggestions? thx.​

    #2
    Hello sdpadre3219,

    If you are submitting ATM strategies you need to use the ATM strategy methods:

    https://ninjatrader.com/support/help...gy_methods.htm
    https://ninjatrader.com/support/help...entryorder.htm

    If you need to do something immediately you need to use OnEachTick processing.

    JesseNinjaTrader Customer Service

    Comment


      #3
      Not sure if this can be done via Strategy Builder or the managed approach.

      Comment


        #4
        Hello Trader17,

        ATM's cannot be used with the strategy builder or the managed approach so those approaches for strategy creation would not apply here.
        JesseNinjaTrader Customer Service

        Comment

        Latest Posts

        Collapse

        Topics Statistics Last Post
        Started by aligator, 01-06-2022, 12:14 PM
        4 responses
        233 views
        0 likes
        Last Post john_44573  
        Started by reynoldsn, Today, 05:56 PM
        0 responses
        4 views
        0 likes
        Last Post reynoldsn  
        Started by bortz, 11-06-2023, 08:04 AM
        51 responses
        1,988 views
        0 likes
        Last Post aligator  
        Started by dmking, 11-12-2019, 12:31 PM
        4 responses
        4,150 views
        0 likes
        Last Post jasonw
        by jasonw
         
        Started by roblogic, Today, 04:31 PM
        0 responses
        10 views
        0 likes
        Last Post roblogic  
        Working...
        X