Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Order handling and Order valid for x minutes

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

    Order handling and Order valid for x minutes

    Hello i have two questions regarding order handling with NT7,

    1) Is it possible to let Ninjatrader send the orders from NT7 to IB without transfering them to the exchange ?

    2) Is it possible to send a time restricted order from NT7 to IB. e.g. once a condition is met, a order gets sent to ib and keeps valid for a specified time.

    What is the syntax i would use to do this.

    Thank you

    #2
    Hello nt2010,

    1) This isn't possible. Once the order has arrived to IB, NinjaTrader has no control on if it's submitted to the exchange.

    2) By Default orders are canceled if not filled on the bar they're submitted on. To change this you have to work with the order method signatures that support liveUntilCanceled property. All order methods have this - below are links to a couple of them:



    As the name suggests, these orders will remain open until Canceled. This reference sample can help with CancelOrder() and the needed IOrder object structure:
    Using CancelOrder() method to cancel orders
    Ryan M.NinjaTrader Customer Service

    Comment


      #3
      Hello,

      regarding the time how long an order is valid i have read about the time in force in the help section. this might would do what i want.
      But i can only read about "day" and "GTC".

      What would be the setting, if every order should only be valid for 5 minutes and then cancels automaticly ?
      (in the unmanaged aproach).

      Thank you for your help
      NT2010

      _____________________
      Definition
      Sets the time in force property for all orders generated by a strategy. This property is dependant on what time in force your broker may or may not support.

      Property Value
      Cbi.TimeInForce.Day
      Cbi.TimeInForce.Gtc

      Syntax
      TimeInForce


      Examples
      protected override void Initialize()
      {
      TimeInForce = Cbi.TimeInForce.Day;
      ___________________________

      Comment


        #4
        nt2010, then you would need to custom code cancelling the order after your desired timespan, or you submit them from a 5 minute chart so they last one bar before expiring (default NT behavior if not sent with the liveUntilCancelled property = true)

        Comment

        Latest Posts

        Collapse

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