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

Hiding/Unhiding chart bars

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

    Hiding/Unhiding chart bars

    Hi Folks:

    I am looking to add the option to hide/unhide bars programmatically from my indicator to increase usability. I used the transparency trick to hide them, but I think is lacking cause it doesn't hides them entirely with kagi lines, line on close, mountain and with point and figure. So I am looking to:

    1 - hide everything properly
    2 - best approach to unhide programmatically everything

    Regards

    #2
    Hello waldoalvarez,

    It is possible to set the ChartBars.Properties.ChartStyle.IsVisible to false to hide the char bars. (Unfortunately, the IsTransparent is read only)

    There would need to be some kind of series visible for the time and price scales to work. This could be an indicator plot or a data series.

    You could also set the Stroke and Stroke2 brush if you would like to hide Kagi, or the UpBrush and DownBrush to hide mountain, line on close, and point and figure.
    if (ChartBars.Properties.ChartStyleType == ChartStyleType.KagiLine)
    ChartBars.Properties.ChartStyle.Stroke2.Brush = Brushes.Transparent;
    Chelsea B.NinjaTrader Customer Service

    Comment


      #3
      Hi Chelsea, Thanks for your reply. I added two transparent plots with high and low. This mostly works but unfortunately when the chart is in autosize mode (pressing the F button) it totally fails giving me a chart with not scale (starting at 0 and 0.1 value visible). Not sure if this is a bug or I should do something else. If I drag the price axis (and the F button appears) it works perfectly.

      Comment


        #4
        Hello waldoalvarez,

        Plots that are transparent will not be plotted. So they will not affect the time and price scales.

        There would need to be some kind of series visible for the time and price scales to work. This could be an indicator plot or a data series.
        Chelsea B.NinjaTrader Customer Service

        Comment


          #5
          Thank you very much Chelsea!

          Comment

          Latest Posts

          Collapse

          Topics Statistics Last Post
          Started by funk10101, Today, 09:43 PM
          0 responses
          6 views
          0 likes
          Last Post funk10101  
          Started by pkefal, 04-11-2024, 07:39 AM
          11 responses
          37 views
          0 likes
          Last Post jeronymite  
          Started by bill2023, Yesterday, 08:51 AM
          8 responses
          44 views
          0 likes
          Last Post bill2023  
          Started by yertle, Today, 08:38 AM
          6 responses
          26 views
          0 likes
          Last Post ryjoga
          by ryjoga
           
          Started by algospoke, Yesterday, 06:40 PM
          2 responses
          24 views
          0 likes
          Last Post algospoke  
          Working...
          X