Jump to content
Software FX Community

ChartFx inside updatepanel


Recommended Posts

Hello Everybody,

I have been working the wholeday trying to make ChartFX inside ASP.net Ajax UpdatePanel. It seems to work when I choose rendering as Image and inject the control into Placeholder upon any changes made to the Chart object. Basically I would like the abilty of adding Series, Points and Axis at runtime based on user selection. I am initially displaying three series but want to add more series based on a user selection.Basically I thought this would save time since only the relevent series gets displayed initially and then I can add one or more series later. But now I think selectively adding series is not possible since SeriesAttributeCollection gets reset everytime page init occurs. Currently I am looping through all the series and adding them to the Chart even though some series are already displayed in the screen and no changes have been made to them. I have set EnableViewState to true and UseCallbacksForEvents to false for the Chart object.Is there anyway this can be done in chartfx?



Link to comment
Share on other sites

The Series collection represents the Series attributes, not the series themselves. The number of series in the chart is determined by the data.

So to add a series, you need to do:


Then you can access the Series collection to customize the attributes of the newly added series.

Link to comment
Share on other sites

Thanks for the reply Frank. I am already doing that when I want to add a new series. But the problem is Chart object in the page seems for forget everthing about the series and points after a async postback. Since I have chart object inside a update panel I want to load only the new series when the user chooses the series name thro a check box. Since some series are already displayed before the checkbox checked event fired I want to add only the new series to the chart object. But since Chart.Data.Points, Chart.Data.Series and the DataValues themselves seem to mysteriously reset themselves everytime an async postback occurs I have to readd all the series and point information again and again when user selects the checkbox eventhough some series are already displayed. i dont think this is an efficient solution. anything i am missing here? thanks

Link to comment
Share on other sites

  • 1 year later...

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Create New...