We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date
close icon

Grouping Stacked Series issues

Hi all,

Since changing to a Group Stacked Series my chart behaves strange (Sample attached).

I think it has something to do with the way I call my ColumnChartViewModel Class or my Observable Collection? If I do it from within the Class itself it's fine:

Me.InternodeUsage = New ObservableCollection(Of InternodeUsage)()
Dim yr As New DateTime(2002, 5, 1)
InternodeUsage.Add(New InternodeUsage() With {.iDate = "12/02/2014", .iTotal = 0.45, .iUp = 0.1, .iDown = 4.5})

But if I do it from within my MainPage if doesn't work:

Dim InternodeData As New ColumnChartViewModel
Dim yr As New DateTime(2002, 5, 1)
InternodeData.InternodeUsage.Add(New InternodeUsage() With {.iDate = "12/02/2014", .iTotal = 0.45, .iUp = 0.1, .iDown = 4.5})

Using a standard Collum chart it all worked fine. Maybe I have been doing it wrong all along . . . ?

Can someone help?

Cheers, Leigh.
















Attachment: Grouping_Stacked_Series_4ff516ec.rar

5 Replies

SS Suresh S Syncfusion Team May 23, 2014 01:29 PM UTC

Hi Leigh,


We have analyzed the stated issue. The issue can be fixed by changing the DateTime format for the given collection class as in the below code snippet. Also, we have prepared the sample based on your query. Please download it from the given below location.

Code snippet [C#]:

Dim yr As New DateTime(2002, 5, 1)

InternodeData.InternodeUsage.Add(New InternodeUsage() With {.iDate = "02/12/2014", .iTotal = 0.45, .iUp = 0.1, .iDown = 4.5})

InternodeData.InternodeUsage.Add(New InternodeUsage() With {.iDate = "02/13/2014", .iTotal = 5.35, .iUp = 0.2, .iDown = 1.5})

 

Please let us know if you request further assistance on this.

 

Regards,

Suresh S.


Attachment: Grouping_Stacked_Series_4ff516ec_adca2c5d.zip


LE Leigh May 23, 2014 02:45 PM UTC

Hi Suresh,

I am in Australia therefore 20/01/2013 is a valid date. When I run the sample now it throws an exception as it can't convert the string to date format. The sample I uploaded works . . . it just doesn't draw the chart correctly (Only shows the iTotal value not iUp, iDown and iTotal).

Thanks, Leigh.




SS Suresh S Syncfusion Team May 26, 2014 11:22 AM UTC

Hi Leigh,


Sorry for the inconvenience caused. We have analyzed the stated issue with your sample and we could find that ItemsSource for other series are not provided, by adding as mentioned in the below code snippet the sample is running without any issue. Please find the modified sample under the following location.


Code Snippet [C#]:

Me.BottomHistoryChart.Series(1).ItemsSource = Nothing

Me.BottomHistoryChart.Series(1).ItemsSource = InternodeData.InternodeUsage

Me.TopHistoryChart.Series(1).ItemsSource = Nothing

Me.TopHistoryChart.Series(1).ItemsSource = InternodeData.InternodeUsage

Me.BottomHistoryChart.Series(2).ItemsSource = Nothing

Me.BottomHistoryChart.Series(2).ItemsSource = InternodeData.InternodeUsage

Me.TopHistoryChart.Series(2).ItemsSource = Nothing

Me.TopHistoryChart.Series(2).ItemsSource = InternodeData.InternodeUsage

 

Please let us know if you require further assistance on this.


Regards,

Suresh S 


Attachment: Grouping_Stacked_Series_4ff516ec_(1)_378393fa.zip


LE Leigh June 2, 2014 07:41 AM UTC

Suresh . . .you are a legend. Can't believe I missed it.

Thanks it works perfect!



SS Suresh S Syncfusion Team June 5, 2014 07:15 AM UTC

Thanks for your update.

We are glad that the issue resolved at your end. As always, we will be happy to assist you.


Regards,

Suresh S


Loader.
Live Chat Icon For mobile
Up arrow icon