set bar chart bar colour based on value

Thread is closed for posting
2 posts, 0 answers
  1. paul
    paul avatar
    2 posts
    Member since:
    May 2013

    Posted 02 Aug 2016 Link to this post

    I am using a custom bar renderer to set the bar colour based on the value

    protected override void RenderPointCore(Canvas canvas, DataPoint point)

    However there doesnt seem to be a "Value" attribute ie point.Value.

    I have created a bodge woraround comparing bar height with canvas height

    Am i missing something?

  2. Victor
    Victor avatar
    1358 posts

    Posted 02 Aug 2016 Link to this post

    Hi Paul,

    Thanks for writing.
    You are on the right track. All you have to do is cast DataPoint to CategoricalDataPoint. DataPoint is the base class for our data points. CategoricalDataPoint has getValue() and getCategory() methods.
    Please write again if you need further assistance.

    Telerik by Progress
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
Back to Top