Displaying grand total in a stacked "unknown" series bar chart

2 posts, 0 answers
  1. Ricard Bertran Vall
    Ricard Bertran Vall avatar
    18 posts
    Member since:
    Sep 2009

    Posted 27 Jun Link to this post

    Requirements

    Telerik Product and Version

    UI for ASP.NET AJAX 

    Supported Browsers and Platforms

    IE11+, Chrome, FireFox

    Components/Widgets used (JS frameworks, etc.)

    jQuery


    PROJECT DESCRIPTION 

    The example below demonstrates how to place a label with the stack total on top of column or bar series in a RadHtmlChart 
    It uses RadHtmlChart just to render KendoUI

    It works with "unknown" (at design-time) series.

    It works with data values on each series. E.g.:

    {
      "series": [
        {
          "name": "Holidays",
          "stack": "HolidaysAndWorkingDays",
          "data": [ 80, 16, 104, 112 ],
          "labels": {
            "visible": true,
            "template": "#= value #",
            "position": "insideEnd",
            "background": "transparent"
          }
        },
        {
          "name": "WorkingDays",
          "stack": "HolidaysAndWorkingDays",
          "data": [ 168, 32, 214, 216 ],
          "labels": {
            "visible": true,
            "template": "#= value #",
            "position": "insideEnd",
            "background": "transparent"
          }
        }
      ],
      "categories": [ "Hines Briggs Alana", "Winters Alford Alexa", "Woodward Thornton Dana", "Clarke Atkinson Perry" ]
    }

    This project is based on and extends the following support threads:

    Show Total for Stacked Series

    Displaying Grand Total In Stacked Series Labels And Pie Series Legend

  2. Marin Bratanov
    Admin
    Marin Bratanov avatar
    3595 posts

    Posted 30 Jun Link to this post

    Hello Richard,

    Thank you for sharing your solution with the community. I have updated your Telerik points as a small token of gratitude.

    I hope people will find your sample useful.

    Regards,

    Marin Bratanov
    Telerik
    Do you need help with upgrading your ASP.NET AJAX, WPF or WinForms projects? Check the Telerik API Analyzer and share your thoughts.
Back to Top