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.
Syncfusion Feedback

Changin Y value

Thread ID:

Created:

Updated:

Platform:

Replies:

117391 Oct 12,2014 09:30 AM Oct 13,2014 12:35 AM JavaScript 1
loading
Tags: ejChart
sandeep
Asked On October 12, 2014 09:30 AM

Hi

How to change the y values dynamically.

for example i have a default chart using datasource if i click the button the chart y values are need to change dynamically.

Thanks in advance

Akbar Basha K M [Syncfusion]
Replied On October 13, 2014 12:35 AM

Hi Mathi,

Thanks for using syncfusion product. We have analyzed your requirement and we like to inform you that you can achieve your requirement using button click event as follows,

function Click(){

var chart = $("#container").ejChart("instance");

  var len = chart.model.series[0].points.length;

for (var i = 0; i < len; i++){

chart.model.series[0].dataSource[i].y =  Math.floor(Math.random() * 700) + 200;

}  $("#container").ejChart("redraw");}

We have prepared a sample based on this. Please find the attached sample.

Please let us know if you have any concern.

Thanks,

Akbar Basha KM.


Attachment: y_b548f214.zip

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.

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

;