Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Orders not coming through

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

    Orders not coming through

    I am trying to understand why my orders are not getting filled.
    At the start of my strategy I have a certain condition:

    int moreContracts = 3;

    if(A == 1)
    {
    EnterLong(1);
    }

    and it works just fine at real time... along the code, if that condition change and A == 3 (for instance), I would like to add more contracts using the variable moreContracts declared above:

    if(A == 3)
    {
    EnterLong(moreContracts);
    }

    The problem is that when it tries to buy more contracts, I get an error on the order fill.
    I get the message attached to this post.
    I already renamed the DB file to OLDNinjatrader.sdf, so the system would generate a new one, but I still get the same error.

    All I want to do is buy more contracts when a certain condition change, how do I do that?

    Thanks a lot.


    Attached Files

    #2
    Hello Eddie De Meira,

    Thank you for the post.

    From the details I couldn't say what may be happening here. Do you have any other logic which may change orders or trail?

    The error indicates a change order, submitting a new entry should not trigger a change order but a new execution. If you can provide more details about your script that may help to see what is happening.


    I look forward to being of further assistance.

    Comment


      #3
      Hi Jesse,
      thank you so much for getting in touch

      Actually, there is no other logic that would be changing the orders, at least, not that I could see... One other interesting thing, is that it works on the Strategy Analyzer or using the SIM account.
      I changed my strategy to compensate for this problem and it seems to be working even better now... let me try for this week and if I still have problems, I will get in touch again.

      Thanks a lot Jesse.

      Comment

      Latest Posts

      Collapse

      Topics Statistics Last Post
      Started by CarlTrading, 03-31-2026, 09:41 PM
      1 response
      84 views
      1 like
      Last Post NinjaTrader_ChelseaB  
      Started by CarlTrading, 04-01-2026, 02:41 AM
      0 responses
      46 views
      0 likes
      Last Post CarlTrading  
      Started by CaptainJack, 03-31-2026, 11:44 PM
      0 responses
      66 views
      2 likes
      Last Post CaptainJack  
      Started by CarlTrading, 03-30-2026, 11:51 AM
      0 responses
      69 views
      0 likes
      Last Post CarlTrading  
      Started by CarlTrading, 03-30-2026, 11:48 AM
      0 responses
      58 views
      0 likes
      Last Post CarlTrading  
      Working...
      X