RadChart AxisX Grouping by Date

2 posts, 0 answers
  1. theBoss
    theBoss avatar
    6 posts
    Member since:
    Feb 2012

    Posted 02 Nov 2013 Link to this post

    Hi,
    I have a datasource consisting on date, id, alarm description and alarm count. I need to show the items grouped by alarm description for the legend and also by date in the x axis. This means the x axis will show the id's grouped by date. I'm using silverlight controls. The following is my current code:

                radChResults.DefaultView.ChartArea.AxisX.Title = "Alarm Count";
                radChResults.DefaultView.ChartArea.AxisY.Title = "Gateway ID";
                radChResults.DefaultView.ChartArea.AxisX.AutoRange = true;
                radChResults.DefaultView.ChartArea.AxisY.AutoRange = true;

                SeriesMapping seriesmapping = new SeriesMapping();
                seriesmapping.SeriesDefinition = new HorizontalBarSeriesDefinition();
                seriesmapping.GroupingSettings.GroupDescriptors.Add(new ChartGroupDescriptor("GWAlarmDesc"));
                seriesmapping.ItemMappings.Add(new ItemMapping("GWayID", DataPointMember.YValue));
                seriesmapping.ItemMappings.Add(new ItemMapping("GWAlmCount", DataPointMember.XValue));

                radChResults.SeriesMappings.Add(seriesmapping);

    Thank you for your help.


                radChResults.ItemsSource = ALCSort;
  2. Petar Marchev
    Admin
    Petar Marchev avatar
    968 posts

    Posted 06 Nov 2013 Link to this post

    Hello Brian,

    I am unsure what is your question about the grouping feature. Have you checked this online example?

    Regards,
    Petar Marchev
    Telerik
    TRY TELERIK'S NEWEST PRODUCT - EQATEC APPLICATION ANALYTICS for SILVERLIGHT.
    Learn what features your users use (or don't use) in your application. Know your audience. Target it better. Develop wisely.
    Sign up for Free application insights >>
  3. DevCraft banner
Back to Top