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.
Unfortunately, activation email could not send to your email. Please try again.

Default "Series 0"

Thread ID:

Created:

Updated:

Platform:

Replies:

53693 Dec 19,2006 03:24 AM Dec 27,2006 09:50 AM ASP.NET Web Forms (Classic) 8
loading
Tags: Chart
Lucie
Asked On December 19, 2006 03:24 AM

Hello,

When I try to display my graph without series, I get a default serie with displayed text : "Series 0". My problem is that this serie appears even if I add my own series ! How can I remove it ?

Thanks for your help.


Administrator [Syncfusion]
Replied On December 19, 2006 11:03 AM

Hi Lucie,

Sorry for my delayed response.

Please find the attached sample which will help you to create an Empty Chart.

Empty Web Chart sample

Please let me know if this helps.

Thank you for your continued interest in Syncfusion products.

Best Regards,
Sureshbabu

Lucie
Replied On December 20, 2006 04:20 AM

Hello,

Unfortunately, it doesn't help me. I have to precise that my graph is not initialized in the html side, I mean I have a class which create my graph and put it in a placeholder. I have this :



Public Class CourbeInclusion

[...]

Private GraphInclusion As ChartWebControl
Private SerieAttenduesInclusion As ChartSeries
Private SerieReellesInclusion As ChartSeries

[...]

Public Sub New()

Me.GraphInclusion = New ChartWebControl
Me.SerieAttenduesInclusion = Me.GraphInclusion.Model.NewSeries
Me.SerieReellesInclusion = Me.GraphInclusion.Model.NewSeries
[...]

End Sub

Public Sub InitData()

[...]

While retour.Read()

[...]

Me.SerieAttenduesInclusion.Points.Add(..., ...)
Me.SerieReellesInclusion.Points.Add(..., ...)
label = New ChartAxisLabel(...)
Me.GraphInclusion.PrimaryXAxis.Labels.Add(label)

[...]

End While

[...]

Me.GraphInclusion.Series.Add(Me.SerieAttenduesInclusion)
Me.GraphInclusion.Series.Add(Me.SerieReellesInclusion)

[...]

Me.GraphInclusion.LegendPosition = ChartDock.Bottom
Me.GraphInclusion.Legend.BackColor = Color.LightYellow

[...]

End Sub

Public Sub AfficheGraphique(ByVal Ph As PlaceHolder)
Ph.Controls.Add(Me.GraphInclusion)
End Sub

End Class



It is allright but I have 3 series appearing in my graph, my owns and one more : "Series 0" ?!??

Thanks

Administrator [Syncfusion]
Replied On December 20, 2006 01:57 PM

Hi Lucie,

Sorry for the inconveniences caused.

Please try any one of the below methods to remove the default series.

1) Before adding series to ChartWebControl, you may clear the default series using ‘Clear’ method. For example,

Me.GraphInclusion.Series.Clear()
Me.GraphInclusion.Series.Add(Me.SerieAttenduesInclusion)
Me.GraphInclusion.Series.Add(Me.SerieReellesInclusion)

2) Or after adding the series to ChartWebControl, you may remove the default series using ‘RemoveAt’ method. For example,

Me.GraphInclusion.Series.Add(Me.SerieAttenduesInclusion)
Me.GraphInclusion.Series.Add(Me.SerieReellesInclusion)
Me.GraphInclusion.Series.RemoveAt(0)

Please let me know if you have any further questions.

Thanks for your patience.

Regards,
Sureshbabu

Lucie
Replied On December 21, 2006 03:32 AM

Hi

Unfortunately it doesn't help me :

The clear method doesn't change the result, 3 series appear instead of 2.

The remove method removes my first serie, but doesn't remove the default serie.

An other idea ?

Lucie
Replied On December 21, 2006 03:43 AM

I don't understand, If I do :

Dim toto As Integer = Me.GraphInclusion.Series.Count

I have the good result : 2, but 3 series appear !!?!!?

I give you a copy of my screen.

syncfusion31.zip

Administrator [Syncfusion]
Replied On December 22, 2006 02:47 PM

Hi Lucie,

Sorry for the delay in my response.

I am not able to reproduce the mentioned issue.

Can you send me a sample which reproduces the issue? It will be easy to fix the issue.

Please let me know if you have any more questions.

Thanks for your interest in Syncfusion products.

Regards,
Sureshbabu

Administrator [Syncfusion]
Replied On December 26, 2006 12:50 PM

Hi Lucie,

Sorry for the delay in getting back to you.

The above mentioned issue is a known issue. Please follow the below steps to prevent this issue.
1) Add an empty Chart control to ‘Place holder’.
2) Later, add series to that Chart control.

Please have a look at the sample code.

[VB]
Ph.Controls.Add(Me.GraphInclusion)
InitData()

Here I have attached a work around sample for this issue which will explain you more clearly.

Chart without Default Series sample

Thanks for your patience.

Best Regards,
Sureshbabu

Lucie
Replied On December 27, 2006 09:50 AM

Hi

It seems to work great in this order !!!!

Thanks again for your help :)

Lucie

CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.

;