Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

can Ninjascript get the selected ATM parameters?

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

    can Ninjascript get the selected ATM parameters?

    would like to know how to do that...

    #2
    Hello llanqui,

    Thanks for your post.

    You could use Atm Strategy Methods if you would like to submit an entry order with an ATM Strategy Template attached to the order to control stops and targets.

    Atm Strategy Methods: https://ninjatrader.com/support/help...gy_methods.htm

    See the SampleAtmStrategy reference sample that comes default with NinjaTrader demonstrating how Atm Strategy Methods could be used. To view the script, open a New > NinjaScript Editor window, open the Strategies folder, and double-click on the SampleAtmStrategy file.

    Otherwise, there would be no other means available for getting ATM Strategy Template parameters in a custom NinjaScript.
    <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


      #3
      Adding to this thread...

      How can a dropdown list be added to the Script in order to choose the ATM Strategy to use? This is for applying the Strategy to other instruments, where a static ATM strategy does not fill all.

      Comment


        #4
        Hello carlosgutierrez,

        Thanks for your notes.

        Please see the forum thread linked below detailing how to create a custom ATM selector in your script.

        <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


          #5
          Thanks Brandon.
          Do you have a link or sample code to see how to add the selected ATM strategy to the executed trade?



          Comment


            #6
            Hello carlosgutierrez,

            Thanks for your notes.

            You could view the sample code shared by my colleague Chris on the forum thread linked in post # 4.

            In the sample, we can see that the name of the public string property is called 'AtmStrategy' which holds the selected Atm Strategy Template name. You could pass AtmStrategy in for the string strategyTemplateName argument when calling AtmStrategyCreate().

            AtmStrategyCreate(OrderAction action, OrderType orderType, double limitPrice, double stopPrice, TimeInForce timeInForce, string orderId, string strategyTemplateName, string atmStrategyId, Action<Cbi.ErrorCode, string> callback)

            See this help guide page for more information about AtmStrategyCreate(): https://ninjatrader.com/support/help...tegycreate.htm
            <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 Geovanny Suaza, 02-11-2026, 06:32 PM
            0 responses
            642 views
            0 likes
            Last Post Geovanny Suaza  
            Started by Geovanny Suaza, 02-11-2026, 05:51 PM
            0 responses
            366 views
            1 like
            Last Post Geovanny Suaza  
            Started by Mindset, 02-09-2026, 11:44 AM
            0 responses
            107 views
            0 likes
            Last Post Mindset
            by Mindset
             
            Started by Geovanny Suaza, 02-02-2026, 12:30 PM
            0 responses
            569 views
            1 like
            Last Post Geovanny Suaza  
            Started by RFrosty, 01-28-2026, 06:49 PM
            0 responses
            573 views
            1 like
            Last Post RFrosty
            by RFrosty
             
            Working...
            X