Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Dynamic Stops and Targets

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

    Dynamic Stops and Targets

    Hello, I have been trying to understand how to get dynamic stops and targets in my strategy (attached). The NT8 guide says to call them in OnBarUpdate instead of State.Configure or State.DataLoaded. However, on the chart, when I move them they snap back after a few seconds. I could create an ATM strategy with moveable stops & targets but is this the only way?
    Attached Files

    #2
    Hello JohnS52,

    In order to be able to move targets that a strategy submits you need to use regular exit orders isntead of the Set methods and also ensure that your condition to submit the orders is only called one time. Once the orders are active you can then manually move them.

    A live until cancelled order is also needed so you would need to use the following overload for the target orders:

    Code:
    ExitLongStop(0, true, 1, Position.AvgPrice - 10 * TickSize, "MyExit", "MyEntry");

    Comment


      #3
      Hello NinjaTrader_Jesse,

      Thank you for your reply. Is there a sample strategy that shows this code in context?

      Comment


        #4
        Hello JohnS52,

        You can see the following sample which submits live until cancelled orders based on an entry fill, the targets are only submitted once when the entry has filled.

        Hello, I have a strategy that places stop and target orders once an order is executed. However, when i see the orders on the chart trader and I want to move


        Comment


          #5
          That works great. Thank you.

          Comment

          Latest Posts

          Collapse

          Topics Statistics Last Post
          Started by NullPointStrategies, Today, 05:17 AM
          0 responses
          46 views
          0 likes
          Last Post NullPointStrategies  
          Started by argusthome, 03-08-2026, 10:06 AM
          0 responses
          126 views
          0 likes
          Last Post argusthome  
          Started by NabilKhattabi, 03-06-2026, 11:18 AM
          0 responses
          66 views
          0 likes
          Last Post NabilKhattabi  
          Started by Deep42, 03-06-2026, 12:28 AM
          0 responses
          42 views
          0 likes
          Last Post Deep42
          by Deep42
           
          Started by TheRealMorford, 03-05-2026, 06:15 PM
          0 responses
          46 views
          0 likes
          Last Post TheRealMorford  
          Working...
          X