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

ATM Error: Close operation failed. Operation timed out. Manually close your position

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

    ATM Error: Close operation failed. Operation timed out. Manually close your position

    Hello.

    I made strategy, witch run ATM strategy.
    My strattegy place ATM entry stop orders in both directions (AtmStrategyCreate() ).
    Predefined ATM strategy place it own stop_loss and take_profit orders.
    After ATM initiated - my strategy changing ATR stop loss (AtmStrategyChangeStopTarget())

    After continuous real-time testing I got error: "Close operation failed. Operation timed out. Manually close your position" and working sell stop order above price. Please, look at attachment.

    What is the reason? How to avoid?
    Attached Files
    fx.practic
    NinjaTrader Ecosystem Vendor - fx.practic

    #2
    Hello fx.practic,

    Thank you for your post.

    Are you using the AtmStrategyClose() function in your script? - AtmStrategyClose(): https://ninjatrader.com/support/help...ategyclose.htm

    Can you send me your log and trace files so I may look into this matter further?

    You can do this by going to the Control Center-> Help-> Mail to Platform Support. Ensuring 'Log and Trace Files' is checked will include these files. This is checked by default. Please list 'ATTN: Patrick H' in the subject line and reference this thread in the body of your email.

    I look forward to assisting you further.

    Comment


      #3
      Log and Trace sent.

      Yes, I using AtmStrategyClose() to close position.

      I want to ask once more question here:
      If have ATM strategy created and entry order placed, and I need to cancel both order and strategy, would it be correct to use AtmStrategyClose() only?
      Or I should use AtmStrategyCancelEntryOrder() too?
      fx.practic
      NinjaTrader Ecosystem Vendor - fx.practic

      Comment


        #4
        Hello fx.practic,

        Thank you for your response.

        If the entry order has not filled then you would use AtmStrategyCancelEntryOrder(): https://ninjatrader.com/support/help...entryorder.htm

        If the positions is open then you would use AtmStrategyClose(): https://ninjatrader.com/support/help...ategyclose.htm

        Please answer my email as I have followed up with additional items.

        Comment


          #5
          Hello,

          Thank you for your patience.

          This is not necessarily caused by your strategy. This occurs when an order fills at the same time that an associated order by OCO ID is in a state of Pending Change.

          This seems to only occur on the Sim101 account. To resolve have the client reset the simulator.
          • From the NinjaTrader Control Center window select the Accounts tab
          • Right click on your simulation account and select 'Edit Account'
          • Press the "Reset" button

          Please let us know if we may be of further assistance.

          Comment

          Latest Posts

          Collapse

          Topics Statistics Last Post
          Started by Christopher_R, Today, 12:29 AM
          0 responses
          9 views
          0 likes
          Last Post Christopher_R  
          Started by sidlercom80, 10-28-2023, 08:49 AM
          166 responses
          2,235 views
          0 likes
          Last Post sidlercom80  
          Started by thread, Yesterday, 11:58 PM
          0 responses
          3 views
          0 likes
          Last Post thread
          by thread
           
          Started by jclose, Yesterday, 09:37 PM
          0 responses
          8 views
          0 likes
          Last Post jclose
          by jclose
           
          Started by WeyldFalcon, 08-07-2020, 06:13 AM
          10 responses
          1,415 views
          0 likes
          Last Post Traderontheroad  
          Working...
          X