Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Double Entry

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

    #16
    PendingSubmit means you "submitted" the order. This does not mean your brokerage or exchange received them. You should check for Accepted.
    Josh P.NinjaTrader Customer Service

    Comment


      #17
      Originally posted by NinjaTrader_Josh View Post
      PendingSubmit means you "submitted" the order. This does not mean your brokerage or exchange received them. You should check for Accepted.
      But by the time I get an "Accepted" state back from the broker, is there the posibility the strategy would have gone on and evaluated the other part of the strategy?

      By using PendingSubmit, you don't need to wait for confirmation from the broker right?

      Comment


        #18
        For sure your strategy could have gone on and did other things.

        It is your call if you don't want to wait for confirmation from brokerage. It could be possible your brokerage never receives the order, rejects it, etc. and you would have triggered other logic based on an assumption that the brokerage accepted your order. If you are OK with that then by all means check for PendingSubmit.
        Josh P.NinjaTrader Customer Service

        Comment


          #19
          Originally posted by NinjaTrader_Josh View Post
          For sure your strategy could have gone on and did other things.

          It is your call if you don't want to wait for confirmation from brokerage. It could be possible your brokerage never receives the order, rejects it, etc. and you would have triggered other logic based on an assumption that the brokerage accepted your order. If you are OK with that then by all means check for PendingSubmit.
          Is it possible to set some flag or some way for the reversal signal to ignore or not execute the "Close Position" order? Using PendingSubmit does test whether the Exit Position triggers or not, however on the same bar I still need to evaluate whether a reversal happened. So I can't just ignore the rest of the code even if PendingSubmit = true.

          Comment


            #20
            Nope. Reversals will always come with a Close position order. If you do not want to reverse just use an Exit() method instead of an Enter() reversal.

            You should just evaluate all of your conditions first. Then decide which order you want to place instead of doing condition A -> submit order -> condition B -> submit another order. Try to evaluate condition A -> condition B -> decide which order to send.
            Josh P.NinjaTrader Customer Service

            Comment


              #21
              Originally posted by NinjaTrader_Josh View Post
              Nope. Reversals will always come with a Close position order. If you do not want to reverse just use an Exit() method instead of an Enter() reversal.

              You should just evaluate all of your conditions first. Then decide which order you want to place instead of doing condition A -> submit order -> condition B -> submit another order. Try to evaluate condition A -> condition B -> decide which order to send.
              Josh, yours is a much better idea. I used flags instead of actual orders during the main body of the strategy. At the end of the strategy, I will just check the flags to determine which orders to send (if there are conflicting ones, just send 1 of them). This eliminate the need for checking the IOrder objects. Cool!

              Comment

              Latest Posts

              Collapse

              Topics Statistics Last Post
              Started by argusthome, 03-08-2026, 10:06 AM
              0 responses
              116 views
              0 likes
              Last Post argusthome  
              Started by NabilKhattabi, 03-06-2026, 11:18 AM
              0 responses
              61 views
              0 likes
              Last Post NabilKhattabi  
              Started by Deep42, 03-06-2026, 12:28 AM
              0 responses
              40 views
              0 likes
              Last Post Deep42
              by Deep42
               
              Started by TheRealMorford, 03-05-2026, 06:15 PM
              0 responses
              43 views
              0 likes
              Last Post TheRealMorford  
              Started by Mindset, 02-28-2026, 06:16 AM
              0 responses
              82 views
              0 likes
              Last Post Mindset
              by Mindset
               
              Working...
              X