Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

OnOrderUpdate

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

    OnOrderUpdate

    There is a critical note associated with OnOrderUpdata:

    Critical: If you want to drive your strategy logic based on order fills you must use OnExecutionUpdate() instead of OnOrderUpdate(). OnExecutionUpdate() is always triggered after OnOrderUpdate(). There is internal strategy logic that is triggered after OnOrderUpdate() is called but before OnExecutionUpdate() that can adversely affect your strategy if you are relying on tracking fills within OnOrderUpdate().

    What I understand is OnOrderUpdate is called before OnExecutionUpdate but can adversely affect your strategy this because of internal strategy logic.

    Can someone explain why such adverse condition?
    What are those internal strategy logic?

    The main differences that I notice belonging to OnExecutionUpdate are related to the execution itself.

    Is this meant that OrderState values cannot be trusted at the time that OnOrderUpdate is triggered?

    Thank you.

    Dan

    #2
    Hello Dan,

    The position may not be updated by the time OnOrderUpdate is triggered but it will be updated by the time OnExecution is triggered.

    Especially for the managed approach, the order handling rules need the position to be updated for the logic for order methods to operate correctly.

    The OrderState of the order should be correct in OnOrderUpdate.
    Chelsea B.NinjaTrader Customer Service

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by NullPointStrategies, Today, 05:17 AM
    0 responses
    44 views
    0 likes
    Last Post NullPointStrategies  
    Started by argusthome, 03-08-2026, 10:06 AM
    0 responses
    124 views
    0 likes
    Last Post argusthome  
    Started by NabilKhattabi, 03-06-2026, 11:18 AM
    0 responses
    65 views
    0 likes
    Last Post NabilKhattabi  
    Started by Deep42, 03-06-2026, 12:28 AM
    0 responses
    42 views
    0 likes
    Last Post Deep42
    by Deep42
     
    Started by TheRealMorford, 03-05-2026, 06:15 PM
    0 responses
    46 views
    0 likes
    Last Post TheRealMorford  
    Working...
    X