Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

NT7 stop orders

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

    NT7 stop orders

    Hi, I am developing a strategy in NT7 beta 13 and I have a question. Can I close a short position by taking a long position?

    What I would like to do is set a EnterLongStop(12); EnterShortStop(10);

    If one of them is filled I would like to use the other one as the stoploss. Using SetStopLoss(Price method) would give me the problem that I don't know at start what direction it should go, so I can't set the stoploss before I enter a Stop order.

    Second question, how to disable/cancel a SetStopLoss()?

    Thanks,
    Johan

    #2
    Johan, you can't cancel a SetStopLoss, only resubmit at other prices by issuing the call again. For more control you want to work with the Enter / Exit methods and the IOrder objects which would allow explicit order cancellations -



    Comment


      #3
      Interesting features Bertrand! Thanks for your response!

      I've found some nice new methods also discussed in


      e.g. SumitOrder()
      SubmitOrder(0,OrderAction.Buy,OrderType.Stop,quantity, <limitprice>, <stopprice>,....,...)

      My question is, if I would like to enter a stop order in this way, I have to set a stopprice as my own stop. But what value to enter for limitprice when I would like the order to go into the market as market order when the stop is triggerd?

      BTW Very nice new features!

      Thanks,
      Johan

      Comment


        #4
        Have already solved my question, should put a 0 into it.

        Other question, while using unmanaged = true

        does Position still contain the actual values? Or do you need to keep track of it yourself?

        Position.MarketPosition == MarketPosition.Flat

        Comment


          #5
          Johan, thanks for the kind words - you can still use the Position object with the unmanaged approach, there's just no signal tracking by NT so you want to store IOrder references for handling this in your code.

          Comment

          Latest Posts

          Collapse

          Topics Statistics Last Post
          Started by Geovanny Suaza, 02-11-2026, 06:32 PM
          0 responses
          633 views
          0 likes
          Last Post Geovanny Suaza  
          Started by Geovanny Suaza, 02-11-2026, 05:51 PM
          0 responses
          364 views
          1 like
          Last Post Geovanny Suaza  
          Started by Mindset, 02-09-2026, 11:44 AM
          0 responses
          105 views
          0 likes
          Last Post Mindset
          by Mindset
           
          Started by Geovanny Suaza, 02-02-2026, 12:30 PM
          0 responses
          567 views
          1 like
          Last Post Geovanny Suaza  
          Started by RFrosty, 01-28-2026, 06:49 PM
          0 responses
          568 views
          1 like
          Last Post RFrosty
          by RFrosty
           
          Working...
          X