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

Cancelling working orders at specified time

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

    Cancelling working orders at specified time

    Is there any way to have Ninja Trader automatically cancel working orders if they are not filled by a specified time?

    For example, I manually place a buy stop above the market and a sell stop below the market and if neither order is filled by 10AM, I want Ninja to automatically cancel the both working orders.

    Is there anything built into Ninja that will handle this situation or would it have to be programmed?

    Thank you.

    Kevin

    #2
    Hello,

    You can change the option: tools>options>Misc.>Fatten time and check flatten all.
    DenNinjaTrader Customer Service

    Comment


      #3
      Wouldn't that cancel all orders at the specified time regardless of whether or not they were filled?

      I only want the orders canceled if they have not been filled at the specified time. If they have been filled, then I don't want them closed until the end of the day or until they hit their target or stoploss.

      Thanks for any help.

      Kevin

      Comment


        #4
        Hello,


        You can only do this manually or in custom NinjaScript programming, sorry.
        DenNinjaTrader Customer Service

        Comment


          #5
          I tried using the Ninja Wizard to program my idea but it was not letting me do what I wanted.

          It seems like it would be simple to program but I am not an experienced programmer.

          Basically what I want to do is program a strategy that will handle the following....

          If Flat and Time >= 10:00 AM then Cancel all working orders

          If anyone can help it would be greatly appreciated.

          Kevin

          Comment


            #6
            Kevin, it sounds like you look for a strategy that would cancel unfilled manually placed orders at a specific time for you...this is unfortunately not supported.
            BertrandNinjaTrader Customer Service

            Comment


              #7
              Kevin,

              You can use this:


              But it will get you 100% flat across everything. You DOM, all open orders, and stop your strategies and of course exit any open positions.

              It's like a hammer.

              I tested it it, and it performed as expected. It essentially is the equivilent to the "Flatten Everything" menu option.

              WARNING: You are on your own. NT will not help you with this as it is not supported. I have not tested it other than on a sim101 account and it did for me what I wanted. Try it on a sim account and go live at your own risk.

              (Don't mean you scare you, but it's par for the course. If you don't know what you are doing, as a rule, don't go outside the scope of what NT will support. If you feel you can produce the result you want and you feel condfident you can get where you need to go, then go for it.)

              Originally posted by kevinh786 View Post
              I tried using the Ninja Wizard to program my idea but it was not letting me do what I wanted.

              It seems like it would be simple to program but I am not an experienced programmer.

              Basically what I want to do is program a strategy that will handle the following....

              If Flat and Time >= 10:00 AM then Cancel all working orders

              If anyone can help it would be greatly appreciated.

              Kevin

              Comment


                #8
                Originally posted by NinjaTrader_Ben View Post
                Hello,

                You can change the option: tools>options>Misc.>Fatten time and check flatten all.
                Ben,

                If I place an order manually in the DOM, then can this Flatten everything command automatically flatten all positions and cancel all extant bracket orders for those positions at the specified Flatten Time?

                Thanks.
                sourcem

                Comment


                  #9
                  Correct, if 'Flatten All' is checked - http://www.ninjatrader-support.com/H...6/MiscTab.html

                  Otherwise, you need to enable it for each position.
                  BertrandNinjaTrader Customer Service

                  Comment

                  Latest Posts

                  Collapse

                  Topics Statistics Last Post
                  Started by jaybedreamin, Today, 05:56 PM
                  0 responses
                  2 views
                  0 likes
                  Last Post jaybedreamin  
                  Started by DJ888, 04-16-2024, 06:09 PM
                  6 responses
                  18 views
                  0 likes
                  Last Post DJ888
                  by DJ888
                   
                  Started by Jon17, Today, 04:33 PM
                  0 responses
                  1 view
                  0 likes
                  Last Post Jon17
                  by Jon17
                   
                  Started by Javierw.ok, Today, 04:12 PM
                  0 responses
                  6 views
                  0 likes
                  Last Post Javierw.ok  
                  Started by timmbbo, Today, 08:59 AM
                  2 responses
                  10 views
                  0 likes
                  Last Post bltdavid  
                  Working...
                  X