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 Price Range Displayed

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

    Chart Price Range Displayed

    Hi,

    is there a way to determine the maximum and minimum price range displayed currently on the chart?

    Thanks,
    Will.

    #2
    Hi Will, I would probably look into getting those directly from the overriden Plot / ChartControls (althought nothing directly documented here by us). A simple idea attached to get started...
    Attached Files
    BertrandNinjaTrader Customer Service

    Comment


      #3
      Thanks Bertrand,

      If I have to use plot override, wouldnt that mean I would have to write all the plotting code for my indicator? That would not really be an option.

      Is there any way to get the values from ChartControls, or any other way, without doing a plot override?

      thanks,
      Will.

      Comment


        #4
        No, the base plotting could be triggered as well, so both approaches would be there. Just add

        base.Plot(graphics, bounds, min, max);

        to the Plot override handler...
        BertrandNinjaTrader Customer Service

        Comment


          #5
          Ok thanks,
          I will give that a try,
          Will.

          Comment


            #6
            Hi, one other problem I'm having related to this is drawing text on a new panel. I created a basic indicator to test with the following code :-

            Plot0.Set(Close[0]);
            DrawText("mytag","mytext",0,1372,Color.Blue); // using instrument GC

            when I set the panel to "new panel" or panel 2, the plot appears on the new panel but the text appears on the price panel.

            is there something extra I have to do to get the text on the new panel?

            Ta,
            Will.

            Comment


              #7
              Sorry, nevermind I discovered DrawOnPricePanel=false;

              Will.

              Comment

              Latest Posts

              Collapse

              Topics Statistics Last Post
              Started by judysamnt7, 03-13-2023, 09:11 AM
              4 responses
              59 views
              0 likes
              Last Post DynamicTest  
              Started by ScottWalsh, Today, 06:52 PM
              4 responses
              36 views
              0 likes
              Last Post ScottWalsh  
              Started by olisav57, Today, 07:39 PM
              0 responses
              7 views
              0 likes
              Last Post olisav57  
              Started by trilliantrader, Today, 03:01 PM
              2 responses
              21 views
              0 likes
              Last Post helpwanted  
              Started by cre8able, Today, 07:24 PM
              0 responses
              10 views
              0 likes
              Last Post cre8able  
              Working...
              X