Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

OnOrderUpdate triggering

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

    OnOrderUpdate triggering

    Hello,

    I´m working with NT8 now for months and all working fine as with NT7 but I have a problem in onorderupdate. I use the logic for OnOrderUpdate from the NT-sample, adding Backcoloring to see if its working. With my entryOrderSba1a=EnterShortLimit(0,true,1,GetCurren tBid(), "Sba1a"); (you can see in the attached screenshot filled) it does not Backbrush nor changing the bool.

    protected override void OnOrderUpdate(Order order, double limitPrice, double stopPrice, int quantity, int filled, double averageFillPrice, OrderState orderState, DateTime time, ErrorCode error, string nativeError)
    {if (entryOrderSba1a != null && order.Name == "entryOrderSba1a")
    {entryOrderSba1a = order;
    if (order.OrderState == OrderState.Filled)
    {shorttrade=true; BackBrush = Brushes.Orange;
    }

    // Reset the entryOrder object to null if order was cancelled without any fill
    if (order.OrderState == OrderState.Cancelled && order.Filled == 0)
    entryOrderSba1a = null;}

    In the attached screenshot one can see that there is an entry from my entryOrderSba1a.

    I try to resolve several times now but I cant figure it out what is the reason.

    Thank you!
    Tony
    Attached Files
    Last edited by tonynt; 09-01-2019, 11:06 AM. Reason: translation error

    #2
    Hi tonynt, thanks for your post.

    Could you kindly post your test script here and so I can run this on my installation?

    I look forward to hearing from you.

    Comment


      #3
      Hello ChrisL,

      thank you for your reply. It is working today with live data! Why didnt it work with playback connection? I worked with this stuff the whole weekend.

      Thank you!
      Tony

      Comment


        #4
        Hi tonynt, thanks for your reply.

        Will this still not work with playback? I would expect the playback account to work the same as the Sim101, but there could be something going on with the fact that the playback account gets reset without user intervention.

        Comment

        Latest Posts

        Collapse

        Topics Statistics Last Post
        Started by Mindset, 04-21-2026, 06:46 AM
        0 responses
        88 views
        0 likes
        Last Post Mindset
        by Mindset
         
        Started by M4ndoo, 04-20-2026, 05:21 PM
        0 responses
        134 views
        0 likes
        Last Post M4ndoo
        by M4ndoo
         
        Started by M4ndoo, 04-19-2026, 05:54 PM
        0 responses
        68 views
        0 likes
        Last Post M4ndoo
        by M4ndoo
         
        Started by cmoran13, 04-16-2026, 01:02 PM
        0 responses
        119 views
        0 likes
        Last Post cmoran13  
        Started by PaulMohn, 04-10-2026, 11:11 AM
        0 responses
        67 views
        0 likes
        Last Post PaulMohn  
        Working...
        X