Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

BarBrush Question

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

    BarBrush Question

    I am trying to adjust the bar paint on my chart to be able to see things quicker. I would like to have code that say if the current bars highs and lows are between the previous bars highs and lows color the bar the same color as the previous bars. I'm pretty sure I have the if statement part right but can't figure out how to say set the current Brushes to the previous Brushes.

    if((High[0] <= High[1]) && (Low[0] >= Low[0]))
    {

    }

    Any help would be great.

    Thanks

    #2
    Hello Tyler7498,

    Thanks for your post.

    The previous bar color will be defined by a condition that say the Close[1] is greater than the Open[1] (upbar) or the Close[1] is less than the Open[1] (down bar).

    You can pull the data series property of what the upbar color is from: ChartBars.Properties.ChartStyle.UpBrush
    You can pull the data series property of what the downbar color is from: ChartBars.Properties.ChartStyle.DownBrush

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by Geovanny Suaza, 02-11-2026, 06:32 PM
    0 responses
    597 views
    0 likes
    Last Post Geovanny Suaza  
    Started by Geovanny Suaza, 02-11-2026, 05:51 PM
    0 responses
    343 views
    1 like
    Last Post Geovanny Suaza  
    Started by Mindset, 02-09-2026, 11:44 AM
    0 responses
    103 views
    0 likes
    Last Post Mindset
    by Mindset
     
    Started by Geovanny Suaza, 02-02-2026, 12:30 PM
    0 responses
    556 views
    1 like
    Last Post Geovanny Suaza  
    Started by RFrosty, 01-28-2026, 06:49 PM
    0 responses
    555 views
    1 like
    Last Post RFrosty
    by RFrosty
     
    Working...
    X