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

Why is only one of the Lines showing?

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

    Why is only one of the Lines showing?

    What do I need to change so that all of the Lines are painted in panel 4?


    ===================
    protected override void Initialize()
    {
    AutoScale = true;
    CalculateOnBarClose = true;
    DisplayInDataBox = false;
    DrawOnPricePanel = false;
    LinesConfigurable = false;
    Overlay = false;
    PaintPriceMarkers = true;
    //PlotsConfigurable = false;
    PriceTypeSupported = false;

    Add(new Plot(new Pen(Color.Black, 5), PlotStyle.Line, "PctB540"));
    Add(new Plot(new Pen(Color.Red, 4), PlotStyle.Line, "PctB180"));
    Add(new Plot(new Pen(Color.Blue, 3), PlotStyle.Line, "PctB60"));
    Add(new Plot(new Pen(Color.Green, 2), PlotStyle.Line, "PctB20"));
    Add(new Plot(new Pen(Color.Gold, 1), PlotStyle.Line, "PctB8"));
    Add(new Plot(new Pen(Color.Purple, 6), PlotStyle.Line, "Try"));

    Add(new Line(Color.FromKnownColor(KnownColor.Red), 100, "100"));
    Add(new Line(Color.FromKnownColor(KnownColor.Black), 50, "50"));
    Add(new Line(Color.FromKnownColor(KnownColor.Blue), 25, "25"));
    Add(new Line(Color.FromKnownColor(KnownColor.White), 0, "Zero"));
    Add(new Line(Color.FromKnownColor(KnownColor.Black), -50, "-50"));
    Add(new Line(Color.FromKnownColor(KnownColor.Blue), -25, "-25"));
    Add(new Line(Color.FromKnownColor(KnownColor.Green), -100, "-100"));
    =================
    Attached Files

    #2
    Saroj,

    I believe your other lines are simply not in the visible y-axis range being displayed at the moment.
    Josh P.NinjaTrader Customer Service

    Comment


      #3
      Follow-up question

      Originally posted by NinjaTrader_Josh View Post
      Saroj,

      I believe your other lines are simply not in the visible y-axis range being displayed at the moment.
      Yep... that was it... sorry to trouble you with it. Although it confuses me that when I change these lines (later I added one and removed one), I had to remove the indicator entirely and then add it back in for the changes to be reflected on the chart.

      Why is that?

      Comment


        #4
        You would have to do that because you would have to refresh the instance of the indicator with the new lines.
        Josh P.NinjaTrader Customer Service

        Comment

        Latest Posts

        Collapse

        Topics Statistics Last Post
        Started by PhillT, 04-19-2024, 02:16 PM
        4 responses
        34 views
        0 likes
        Last Post PhillT
        by PhillT
         
        Started by ageeholdings, 05-01-2024, 05:22 AM
        5 responses
        37 views
        0 likes
        Last Post ageeholdings  
        Started by reynoldsn, Today, 02:34 PM
        0 responses
        13 views
        0 likes
        Last Post reynoldsn  
        Started by nightstalker, Today, 02:05 PM
        0 responses
        19 views
        0 likes
        Last Post nightstalker  
        Started by llanqui, Yesterday, 09:59 AM
        8 responses
        32 views
        0 likes
        Last Post llanqui
        by llanqui
         
        Working...
        X