Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Instead of BarBrushes how to I say BarOutline?

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

    Instead of BarBrushes how to I say BarOutline?

    Instead of BarBrushes how to I say BarOutline?

    if(Close[1] < Open[1] && Low[0] < Low[1] && Close[0] > Close[1] && BarBrushes[2] != Brushes.RosyBrown)


    {
    BarBrushes[0] = Brushes.RosyBrown;
    BarBrushes[1] = Brushes.Brown;
    }

    I want to keep the original color of the two bars but just have them outlined.
    Attached Files
    Last edited by trdninstyle; 10-06-2022, 09:36 AM.

    #2
    Hello trdninstyle,

    CandleOutlineBrushes
    Chelsea B.NinjaTrader Customer Service

    Comment


      #3
      Hi Chelsea B.

      Thanks for that link. I'm doing something wrong here because it's not displaying on chart. Can you please take a look at my pic?
      Attached Files

      Comment


        #4
        Originally posted by trdninstyle View Post
        Hi Chelsea B.

        Thanks for that link. I'm doing something wrong here because it's not displaying on chart. Can you please take a look at my pic?
        In your pic from post #1 we see the outline is already black. If you want it thicker you need to do that from the ChartStyle button on your toolbar.
        eDanny
        NinjaTrader Ecosystem Vendor - Integrity Traders

        Comment


          #5
          Hello trdninstyle,

          eDanny is correct. Try setting the outline to yellow or something that stands out.

          Also, use prints to confirm the condition is evaluating as true.
          Chelsea B.NinjaTrader Customer Service

          Comment


            #6
            Originally posted by eDanny View Post

            In your pic from post #1 we see the outline is already black. If you want it thicker you need to do that from the ChartStyle button on your toolbar.
            From the pic I drew those bold black lines from paint after I screenshot it. If I did it from ChartStyle then all of the candles would be bold black. I already have a twobar reversal painting the bars but I just want them to be outlined instead and not effecting the color of the bars.

            My bad, I mis read what u were saying. What u said did fix it. Thank you.
            Last edited by trdninstyle; 10-06-2022, 11:30 AM.

            Comment


              #7
              trdninstyle,

              Try setting CandleOutlineBrushes[0] to yellow or something that stands out.

              Use prints to confirm the condition is evaluating as true.
              https://ninjatrader.com/support/foru...121#post791121

              Save the output to a text file and include this with your reply.
              Chelsea B.NinjaTrader Customer Service

              Comment


                #8
                I see what u guys are saying now, sorry it took me so long.
                Attached Files

                Comment


                  #9
                  I grabbed the color Cyan, I'll find a color that looks better. Now if I want it to be black but very bold, could I say BoldBlack?
                  Attached Files
                  Last edited by trdninstyle; 10-06-2022, 01:01 PM.

                  Comment


                    #10
                    Hello trdninstyle,

                    BoldBlack is not a color. Black is color.

                    If you want to increase the outline width right-click the chart -> select Data Series -> expand Chart style -> expand Candle body outline -> set Width to a larger value.

                    Or alternatively, you can create a custom chart style script that renders a different outline width.
                    Chelsea B.NinjaTrader Customer Service

                    Comment


                      #11
                      I tried that it thickens all of them but is there a way in the code to tell it to print thicker?

                      Comment


                        #12
                        Hello trdninstyle,

                        This is not documented, but using undocumented code you can change the chart style stroke width for all candles.
                        Chelsea B.NinjaTrader Customer Service

                        Comment


                          #13
                          Thats interesting tho ...

                          ChartBars.Properties.ChartStyle.Stroke.Width = 6; //Change Candle Outline Width

                          That would be good if the department from up top worked on that and made it an option.

                          I have both Up and Down indicators now but they're separate indicators right now. How would I place both indicators onto one script?
                          Attached Files

                          Comment


                            #14
                            Hello trdninstyle,

                            Copy the logic in OnBarUpdate() in one script over to the other script.

                            You may want to consider using an else if for the second condition.
                            Chelsea B.NinjaTrader Customer Service

                            Comment


                              #15
                              I placed the 2nd one between the brackets with just an 'else'. It was easier than I thought it would be. At first, I had a bunch of errors, but I figured it out. I just have to change the name to indicate up & down. The scary thing is, I'm picking up on this stuff lol Thank you.
                              Attached Files

                              Comment

                              Latest Posts

                              Collapse

                              Topics Statistics Last Post
                              Started by Geovanny Suaza, 02-11-2026, 06:32 PM
                              0 responses
                              647 views
                              0 likes
                              Last Post Geovanny Suaza  
                              Started by Geovanny Suaza, 02-11-2026, 05:51 PM
                              0 responses
                              368 views
                              1 like
                              Last Post Geovanny Suaza  
                              Started by Mindset, 02-09-2026, 11:44 AM
                              0 responses
                              108 views
                              0 likes
                              Last Post Mindset
                              by Mindset
                               
                              Started by Geovanny Suaza, 02-02-2026, 12:30 PM
                              0 responses
                              571 views
                              1 like
                              Last Post Geovanny Suaza  
                              Started by RFrosty, 01-28-2026, 06:49 PM
                              0 responses
                              573 views
                              1 like
                              Last Post RFrosty
                              by RFrosty
                               
                              Working...
                              X