Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Function .Set

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

    Function .Set

    Hello,

    I have an indicator that has the next code in NT7:

    MyIndicadtor.Set(1, IndicatorB[1]);

    How can I traduce this code to NT8?

    Thanks!

    #2
    Hello soyjesus,
    Thanks for your post.

    In NT8 you would simply use an "=" assignment operator along with the appropriate index value, instead of ".Set". The equivalent of this in NT8 would be--

    Code:
    MyIndicator[0] = (1, IndicatorB[1]);
    The following help guide documentation details how you can work with Series<T> objects like this one in NT8.

    Series<T>
    https://ninjatrader.com/support/help...s/?seriest.htm

    Also, as you convert code over from NT7 to NT8 you would be well served by looking through the code-breaking changes, as this will detail what parts of your scripts will need to be changed to be in compliance with NT8's under the hood changes.

    Code Breaking Changes
    https://ninjatrader.com/support/help...ng_changes.htm

    Please let me know if you have any further questions.
    Josh G.NinjaTrader Customer Service

    Comment


      #3
      Thank you for your help and sorry but I have another question about indicators:

      When I am developing a new indicator I need to refresh mi scren continuously to check the changes.
      How can I do it with NT8? Becase at this moment I only can do it removing the indicator from the screen and inserting it again.

      Comment


        #4
        Hello soyjesus,

        In most cases you can right-click inside your chart and select "Reload NinjaScript" to immediately see changes you have made to the script.

        Please let me know if you have any further questions.
        Josh G.NinjaTrader Customer Service

        Comment

        Latest Posts

        Collapse

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