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. (Last updated on: November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Save original chart axis labels

Thread ID:





101568 Nov 2,2011 07:12 PM UTC Nov 4,2011 08:49 AM UTC WPF 1
Tags: Chart
George G
Asked On November 2, 2011 07:12 PM UTC

How can we add an extra text string to a Syncfusion wpf chart?

We need to store an extra hidden text string to a SyncFusion chart. Our users have the ability to edit the chart axis label as well as the data series label. We need to preserver the original label from the first time the chart is displayed to the user.

This will allow the user to revert the edited label back to the original one.

This is for a chart that the user can dynamically add data series to as well as set axis scale, etc.

We're using Syncfusion.Chart.WPF.DLL version in a .net 4.0 WPF desktop application.

Michael Prabhu M [Syncfusion]
Replied On November 4, 2011 08:49 AM UTC

Hi George,

Thanks for using Syncfusion Products, We have analyzed your requirement and it can be achieved by storing the ChartAxisLabelsCollection while loading the chart and then restoring it after editing the axis labels as in below code snippet.

Code snippet[C#]:
Storing the text:
ChartAxisLabelsCollection lc=new ChartAxisLabelsCollection();

Restoring the text:
xaxis.LabelsSource = lc;

We have also prepared a simple sample based on your requirement which you can download from the attachment.

Please let us know if you have any concerns.

Michael Prabhu.



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.

Please sign in to access our forum

This page will automatically be redirected to the sign-in page in 10 seconds.

Warning Icon 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.Close Icon