Setting Graph Colors

5 posts, 0 answers
  1. Thomas
    Thomas avatar
    3 posts
    Member since:
    Jun 2015

    Posted 26 Aug 2015 Link to this post

    Hi

    I have the following problem: A Report containing graphs (a pie and a bar) which show the status of objects.
    This status can be canceled, ok, delayed,…
    I want to set the shown color of the graphs corresponding to the status:
    Ok = green
    Delayed = orange
    And so on.
    If I set the ColorPalette to the desired Colors everything is fine until a status is missing (no object has the status OK) then green is used for the delayed Status and so on.
    Is there a way to enforce the same color for a certain attribute value, even if another attribute value is missing?

     

    Thanks for any help

  2. Nasko
    Admin
    Nasko avatar
    909 posts

    Posted 26 Aug 2015 Link to this post

    Hello Thomas,

    You can set the colors according to the status data field using Conditional Formatting. You will need to add the conditional formatting rules to the DataPointConditionalFormatting property. Further information is present in the provided help article.

    Regards,
    Nasko
    Telerik
    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
  3. DevCraft banner
  4. Thomas
    Thomas avatar
    3 posts
    Member since:
    Jun 2015

    Posted 27 Aug 2015 Link to this post

    Can you elaborate this? How do I set these properties in the Reporter Designer? I have tried setting the Background to a specific color when the Status equals the Status of “ok”. The only Color that changed was the background of the whole graph. What is the right Conditional Formatting Style Element to set the Color of the "Pie parts"?
  5. Thomas
    Thomas avatar
    3 posts
    Member since:
    Jun 2015

    Posted 27 Aug 2015 in reply to Thomas Link to this post

    Ok I found the Element, last post can be ignored!
    A new Problem arose: if I ​change the Conditional Format the Legend of the ​Graph doesn't update accordingly. Is there ​a way to format the Legend?

  6. Nasko
    Admin
    Nasko avatar
    909 posts

    Posted 31 Aug 2015 Link to this post

    Hello Thomas,

    The data points color can be set using the Graph.Series.BarSeries.DataPointConditionalFormatting property.
    The legend markers can be set using the Graph.Series.BarSeries.LegendItem.MarkConditionalFormatting property.

    Regards,
    Nasko
    Telerik
    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
DevCraft banner