Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Multi-Instruments in (OnOrderUpdate & OnExecutionUpdate ).

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

    Multi-Instruments in (OnOrderUpdate & OnExecutionUpdate ).

    Good morning
    I use Multi-Instruments​ in my strategy and it is recommended to use (OnOrderUpdate & OnExecutionUpdate ).
    I tried to use "BarsInProgress" but I see that it is not correct. Please how to do it​ ?

    M.GHORBEL
    Attached Files

    #2
    Hello M.GHORBEL,

    Thanks for your post.

    The warning message in the screenshot you shared could be found on the OnOrderUpdate() and OnExecutionUpdate() help guide documentation linked below.

    From the OnOrderUpdate() help guide:

    "Rithmic and Interactive Brokers Users: When using a NinjaScript strategy it is best practice to only work with passed by value data from OnExecution. Instances of multiple fills at the same time for the same instrument might result in an incorrect OnPositionUpdate, as sequence of events are not guaranteed due to provider API design. For an example on protecting positions with this approach, see OnExecutionUpdate()​"

    From the OnExecutionUpdate() help guide:

    "Rithmic and Interactive Brokers Users: When using a NinjaScript strategy it is best practice to only work with passed by value data from OnExecution. Instances of multiple fills at the same time for the same instrument might result in an incorrect OnPositionUpdate, as sequence of events are not guaranteed due to provider API design."

    OnOrderUpdate(): https://ninjatrader.com/support/help...rderupdate.htm
    OnExecutionUpdate(): https://ninjatrader.com/support/help...tionupdate.htm

    You could view the second section of sample code in the OnExecutionUpdate() help guide page for an example of protecting positions when using Interactive Brokers.

    This forum thread contains RithmicIBFriendlyExample samples that you could view also which demonstrate how to program a NinjaScript strategy to use with Interactive Brokers: https://forum.ninjatrader.com/forum/...72#post1206372
    <span class="name">Brandon H.</span><span class="title">NinjaTrader Customer Service</span><iframe name="sig" id="sigFrame" src="/support/forum/core/clientscript/Signature/signature.php" frameborder="0" border="0" cellspacing="0" style="border-style: none;width: 100%; height: 120px;"></iframe>

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by kinfxhk, 07-14-2026, 09:39 AM
    0 responses
    15 views
    0 likes
    Last Post kinfxhk
    by kinfxhk
     
    Started by kinfxhk, 07-13-2026, 10:18 AM
    0 responses
    59 views
    0 likes
    Last Post kinfxhk
    by kinfxhk
     
    Started by kinfxhk, 07-13-2026, 09:50 AM
    0 responses
    42 views
    0 likes
    Last Post kinfxhk
    by kinfxhk
     
    Started by kinfxhk, 07-13-2026, 07:21 AM
    0 responses
    47 views
    0 likes
    Last Post kinfxhk
    by kinfxhk
     
    Started by kinfxhk, 07-11-2026, 02:11 AM
    0 responses
    38 views
    0 likes
    Last Post kinfxhk
    by kinfxhk
     
    Working...
    X