Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

order Handling based on error type

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

    order Handling based on error type

    Hello. I need to be able to handle various orders. error such as this one.
    "submitted an order that generated the following error 'Unable to change order'"
    I notice a lot of times with NQ the system gets order errors. I don't mind being unable to change the order since I have a stop in place. However, I don't want termination I would prefer to take the loss and ignore the error if it's that one above. or Stop cannot be placed above or below market. Those I can ignore.

    Can you point me to how I can ignore some errors and leave my strategy running?



    #2
    Hello richa61416,

    Thanks for your post.

    You could use RealtimeErrorHandling to determine the behavior of a strategy when the strategy places an order that results in an error.

    RealtimeErrorHandling could be set to IgnoreAllErrors to ignore any order errors received. Please note that setting this property value to IgnoreAllErrors can have serious adverse affects on a running strategy unless you have programmed your own order rejection handling in the OnOrderUpdate() method. To do this you could trap the order within OnOrderUpdate() followed by defining your own order error handling behavior for the order.

    Please see the example in the help guide link below that demonstrates using RealtimeErrorHandling and trapping an order in OnOrderUpdate().

    RealtimeErrorHandling — https://ninjatrader.com/es/support/h...orhandling.htm

    And, see this help guide for information about OnOrderUpdate and the available error codes: https://ninjatrader.com/support/help...rderupdate.htm

    Let me know if I may assist further.
    <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 NullPointStrategies, Yesterday, 05:17 AM
    0 responses
    75 views
    0 likes
    Last Post NullPointStrategies  
    Started by argusthome, 03-08-2026, 10:06 AM
    0 responses
    146 views
    0 likes
    Last Post argusthome  
    Started by NabilKhattabi, 03-06-2026, 11:18 AM
    0 responses
    79 views
    0 likes
    Last Post NabilKhattabi  
    Started by Deep42, 03-06-2026, 12:28 AM
    0 responses
    50 views
    0 likes
    Last Post Deep42
    by Deep42
     
    Started by TheRealMorford, 03-05-2026, 06:15 PM
    0 responses
    54 views
    0 likes
    Last Post TheRealMorford  
    Working...
    X