Sign in to follow this  
arkin

Chart Rerendering

Recommended Posts

Hello,

 

can anyone help me?

how can i rerendering a Chart without disable labels?

When i disable one label with 99% and i have one label with 1% i would like to see the label with 1 % in big format because it is to small when the label with 99% is able!

 

Thank you

Arkin

 

 

Share this post


Link to post
Share on other sites

Hi,

 

It is not possible to re-render a chart without making the legend of a dataset invisible, directly.

 

But as a workaround, you may update the data of a chart at runtime. You may have configuration options for a chart, then do a postback with the configured options, and then update the chart with the newer data from the server.

 

This can be done by obtaining the chart reference by passing the DOM Id of the chart and updating the chart with new XML/JSON data.

Ref.

 //Get reference to chart object using Dom ID
  var chartObj = FusionCharts(domId);
   
//Update it's XML 
     chartObj.setXMLData( "newData");

 

Now, in the new XML/JSON Data, you may set the attribute "visible" of the dataset element to 0, to mark a dataset element invisible  by making the legend of the dataset being visible.
 
Ref. 
<dataset ... visible='0' >
When you do this, the dataset is not visible on the chart but its legend is visible and the corresponding dataset appears when you click on it.
 
Please find an attached sample using the above approach. Also, please note that this works only with JavaScript charts.
 
Hope this helps.

MSLine_Demo.zip

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this