Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Order Cancel Pending

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

    Order Cancel Pending

    Hello,
    I am running a strategy and I run into an issue where occasionally, the strategy will attempt to cancel an order, but the order will be stuck in "cancel pending". How can I change my strategy to avoid this issue?

    #2
    Hello samish18,

    CRITICAL - If your inquiry involves live orders, please always reach out to your broker's Orders Desk immediately to confirm and manage your live orders and positions.

    When an order receives a 'Cancel pending' state, it indicates NinjaTrader Desktop sent the cancellation request to the broker/exchange. Once the order is cancelled, a signal is sent back to NinjaTrader Desktop and the order state will change to 'Cancelled'.

    The display of the 'Cancel pending' order will be removed the next trading day. If not, please perform a restart of NinjaTrader Desktop.

    I'm not sure why the order did not get a 'Cancelled' state. If the order was indeed cancelled, it is likely a connectivity issue. NinjaTrader Desktop did not receive a signal back that the order was cancelled. If the issue persists, please troubleshoot with the steps below. Check if orders are cancelled successful after each step.
    • Restart NinjaTrader
    • Restart your modem and (if applicable) router
    • Restart your PC
    • Clear your DNS
    • - Open the Command Prompt: https://www.howtogeek.com/235101/10-...in-windows-10/
    • - In the command prompt, run this command: ipconfig /flushdns
    • If you are not already and the option is available to you, connect to the internet using an ethernet cable. Wireless connections are significantly more unreliable.
    • Ensure exceptions have been added into any firewall/antivirus/backup programs for the Documents > "NinjaTrader 8" folder.
    • Ensure that your computer is not turning off your Network Adapter to conserve power:
    • - Right-click on your Start button
    • - Select 'Device Manager'
    • - Expand 'Network Adapters'
    • - Right-click on your Network Adapter and select Properties > Power Management
    • - Uncheck 'Allow the computer to turn off this device to save power' option
    • - Click 'OK' to save the changes
    • - Do this for all Network Adapters
    JasonNinjaTrader Customer Service

    Comment


      #3
      I am testing out a strategy on a sim account. When restrarting ninjatrader, the cancel pending is still there. I manually go into document > Ninjatrader 8 > db to reset. I repeatedly run into this issue when running my strategy, my question is how may I change my code to avoid this?

      Comment


        #4
        You can remove the order stuck in a 'Cancel pending' state by resetting the simulation account.
        • Go to Control Center-->Accounts-tab.
        • Right click the simulation account and select 'Edit Account'.
        • Click reset in the lower right.
        • Click Yes-->OK.
        I'm not a programmer myself, so I will not be much help with changing code. Please create a new forum thread under NinjaTrader Desktop - Strategy Development for assistance in this regard.
        JasonNinjaTrader Customer Service

        Comment

        Latest Posts

        Collapse

        Topics Statistics Last Post
        Started by poplagelu, Today, 05:00 AM
        0 responses
        3 views
        0 likes
        Last Post poplagelu  
        Started by fx.practic, 10-15-2013, 12:53 AM
        5 responses
        5,407 views
        0 likes
        Last Post Bidder
        by Bidder
         
        Started by Shai Samuel, 07-02-2022, 02:46 PM
        4 responses
        98 views
        0 likes
        Last Post Bidder
        by Bidder
         
        Started by DJ888, Yesterday, 10:57 PM
        0 responses
        8 views
        0 likes
        Last Post DJ888
        by DJ888
         
        Started by MacDad, 02-25-2024, 11:48 PM
        7 responses
        160 views
        0 likes
        Last Post loganjarosz123  
        Working...
        X