Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Counting the number of orders sent

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

    Counting the number of orders sent

    As I'm begging to hit the messaging limit on CME, what's the best way to count the number of orders (new / replace / cancel) that NT actually sends?

    (I was thinking counting them in OnOrderUpdate(), but perhaps there is a simpler solution).

    Boaz

    #2
    Hi Boaz,

    OnOrderUpdate is the best place if you are interested in monitoring order state changes. Each category you list there can probably be associated with a specific order state.
    new = PendingSubmit
    replace = PendingChange
    Cancel = PendingCancel or Cancelled
    Ryan M.NinjaTrader Customer Service

    Comment


      #3
      While we're at it, what's the best way to determine the order's signal (meaning Entry, Profit Target or Stop Loss). Right now I'm doing
      Code:
      if (order.Name == "Stop loss") {...}
      , but is there somthing more generic and efficient than string comparison?

      Comment


        #4
        boaza, this would be what you need to use with the Set() methods that do not offer IOrder returns, if suitable the IOrder returns offer a more elegant way with the .Name property : http://www.ninjatrader.com/support/h...nt7/iorder.htm

        Comment

        Latest Posts

        Collapse

        Topics Statistics Last Post
        Started by Geovanny Suaza, 02-11-2026, 06:32 PM
        0 responses
        649 views
        0 likes
        Last Post Geovanny Suaza  
        Started by Geovanny Suaza, 02-11-2026, 05:51 PM
        0 responses
        370 views
        1 like
        Last Post Geovanny Suaza  
        Started by Mindset, 02-09-2026, 11:44 AM
        0 responses
        109 views
        0 likes
        Last Post Mindset
        by Mindset
         
        Started by Geovanny Suaza, 02-02-2026, 12:30 PM
        0 responses
        574 views
        1 like
        Last Post Geovanny Suaza  
        Started by RFrosty, 01-28-2026, 06:49 PM
        0 responses
        576 views
        1 like
        Last Post RFrosty
        by RFrosty
         
        Working...
        X