Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Right Scale Chart Properties

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

    Right Scale Chart Properties

    Hi,

    I have two questions:

    1. Is there a way to access the Right Scale settings for a chart?
    2. If Horizontal Grid Lines are set to automatic, how does NT decide where to draw the horizontal line. I would like to find out how far apart the lines on the chart are.

    Thanks for your help.

    #2
    1. Right-click directly on the vertical/price scale to access the scale/panel settings.
    2. You can define how far apart the horizontal grid lines are if you change the 'horizontal grid lines' property to 'fixed'. Then, adjust the 'horizontal grid lines type' and 'horizontal grid lines value' as you desire.

    Comment


      #3
      Thanks, PatrickG.
      I should have said that I want to access these programatically. My apologies. I know that I can get these via ChartScale.Properties but I am having a bit of an issue creating an instance of ChartScale outside of OnRender() so I can get access.

      Comment


        #4
        Hello Zeos6,

        Thank you for the post.

        The suggested way to access the ChartScale object is generally by setting a class level variable to the ChartScale instance that is passed in to OnRender. Can you tell me, are you currently using an Indicator or another type as this is posted in the Addon development forum?

        I look forward to being of further assistance.

        Comment


          #5
          Hi Jesse,


          I am trying to access the various members of ChartScale.Properties programatically from inside indicator so that I can use them for calculations done in the indicator. I am not using OnRender(). Ideally I'd like to get the values of these during OnStateChange() if possible.

          Comment


            #6
            Hello Zeos6,

            Thank you for the reply.

            Because you are using an Indicator, you could either pass a variable from OnRender depending on the use case or you can take a look at the following example:



            The ChartPanel object has a Scales collection which you can iterate over. Depending on what you are trying to affect, you may or may not see an update in the chart when setting the values of UI objects programmatically. You will need to test your idea to see if this object gives that ability.


            I look forward to being of further assistance.

            Comment


              #7
              Thanks Jesse.

              This is actually quite helpful. I thought about the OnRender approach but the Scales approach might actually work better for me. I will give it a try. Thanks for pointing it out.

              Comment

              Latest Posts

              Collapse

              Topics Statistics Last Post
              Started by Geovanny Suaza, 02-11-2026, 06:32 PM
              0 responses
              579 views
              0 likes
              Last Post Geovanny Suaza  
              Started by Geovanny Suaza, 02-11-2026, 05:51 PM
              0 responses
              334 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
              554 views
              1 like
              Last Post Geovanny Suaza  
              Started by RFrosty, 01-28-2026, 06:49 PM
              0 responses
              551 views
              1 like
              Last Post RFrosty
              by RFrosty
               
              Working...
              X