Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

automated system failure

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

    automated system failure

    I have the following code in an automated system. It has been working fine and executing upon a fill in the primary contract. today it failed twice. Is there anyway to track down how or why this could have happened. BY fail i mean this code segment did not submit the order wehn there was a fill in the order specificed by the ZBOrder order



    protected override void OnOrderUpdate(IOrder order)
    {
    if (ZBOrder != null && ZBOrder.Token == order.Token && order.OrderState == OrderState.Filled )
    {

    ZBWrk = true;
    Print("***********************FILL**************** ********");
    Print("QTY:"+order.Quantity.ToString());
    if (sBuySell=="S")
    {
    //ZNOrder = EnterShortLimit(1,true,order.Quantity,GetCurrentBi d(1), "SPRD2");
    ZNOrder = EnterShort(1,order.Quantity,"SPRD2");
    Print("SELL ZN:" + (GetCurrentBid(1)));
    }
    if (sBuySell=="B")
    {
    //ZNOrder = EnterShortLimit(1,true,order.Quantity,GetCurrentBi d(1), "SPRD2");
    ZNOrder = EnterLong(1,order.Quantity,"SPRD2");
    Print("BUY ZN:" + (GetCurrentAsk(1)));
    }


    Print("***********************FILL**************** ********");
    ZBOrder = null;
    }
    }

    #2
    You might be running into an issue we have recently come across that is forcing us to adopt a new advised approach when it comes to triggering order submissions. Instead of OnOrderUpdate() we will advise and provide a reference sample with using OnExecution(). This should be out in the next few days and I suggest re-coding this aspect of your strategy and then letting us know if you see something unexpected again.
    RayNinjaTrader Customer Service

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by Mindset, 04-21-2026, 06:46 AM
    0 responses
    105 views
    0 likes
    Last Post Mindset
    by Mindset
     
    Started by M4ndoo, 04-20-2026, 05:21 PM
    0 responses
    146 views
    0 likes
    Last Post M4ndoo
    by M4ndoo
     
    Started by M4ndoo, 04-19-2026, 05:54 PM
    0 responses
    71 views
    0 likes
    Last Post M4ndoo
    by M4ndoo
     
    Started by cmoran13, 04-16-2026, 01:02 PM
    0 responses
    125 views
    0 likes
    Last Post cmoran13  
    Started by PaulMohn, 04-10-2026, 11:11 AM
    0 responses
    79 views
    0 likes
    Last Post PaulMohn  
    Working...
    X