Announcement

Collapse

Looking for a User App or Add-On built by the NinjaTrader community?

Visit NinjaTrader EcoSystem and our free User App Share!

Have a question for the NinjaScript developer community? Open a new thread in our NinjaScript File Sharing Discussion Forum!
See more
See less

Partner 728x90

Collapse

Chart > Toolbar > IntervalsDisplay > String, change via code?

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

    Chart > Toolbar > IntervalsDisplay > String, change via code?

    Hello,

    I am looking for programmatic access to change the Display string shown on a chart's Toolbar IntervalsDisplay control.

    Code:
    [B]NinjaTrader.Gui.Tools.IntervalsDisplay[/B]


    I want to change the string based on events in my custom BarType, such as during OnDataPoint,
    and not just after the config gui is closed,
    i.e. setting the value of "Name" during a state will work when the bars are loaded,
    and the value of Name can be changed during OnDataPoint, (tested using Print() statements)
    but the string displayed in the Presentation layer does not change.

    I also wonder if I can change the Input string displayed for Indicators at the same time?

    Thanks.


    #2
    Hello balltrader,

    Thanks for your post.

    The Name property in State.Configure determines how the name of the BarsType will display in the Interval drop-down menu on chart.

    This property will also control how the name of the BarsType will display in the indicator label on a chart.

    You may see this by looking at the State.Configure section of the UniRenko custom BarsType script linked below.

    UniRenko: https://ninjatraderecosystem.com/use...nko-bartype-8/

    It is not supported to call the Name property outside of State.Configure, however, you may try changing the Name property dynamically in OnDataPoint() at your own discretion.

    Please let me know if I may assist further.


    The NinjaTrader Ecosystem website is for educational and informational purposes only and should not be considered a solicitation to buy or sell a futures contract or make any other type of investment decision. The add-ons listed on this website are not to be considered a recommendation and it is the reader's responsibility to evaluate any product, service, or company. NinjaTrader Ecosystem LLC is not responsible for the accuracy or content of any product, service or company linked to on this website.
    Brandon H.NinjaTrader Customer Service

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by Haiasi, 04-25-2024, 06:53 PM
    2 responses
    17 views
    0 likes
    Last Post Massinisa  
    Started by Creamers, Today, 05:32 AM
    0 responses
    5 views
    0 likes
    Last Post Creamers  
    Started by Segwin, 05-07-2018, 02:15 PM
    12 responses
    1,786 views
    0 likes
    Last Post Leafcutter  
    Started by poplagelu, Today, 05:00 AM
    0 responses
    3 views
    0 likes
    Last Post poplagelu  
    Started by fx.practic, 10-15-2013, 12:53 AM
    5 responses
    5,407 views
    0 likes
    Last Post Bidder
    by Bidder
     
    Working...
    X