Sign in to follow this  
magiczhang

How Can Change Pie 3D Data Active?

Recommended Posts

Guest Sumedh

Hi,

 

For updating chart data you would need to create a javascript function in your html page and call function on the chartID.

 

Ref. Code:

 

var myChart = new FusionCharts( "Pie3D.swf","myChartId", "700", "600", "0", "1" );

myChart.setXMLUrl("data1.xml");

myChart.render("chartContainer");

function changeWeek()

{

var chartReference = FusionCharts("myChartId");

chartReference.setXMLUrl("data2.xml");

}

 

Here in above code, Pie3D chart is rendered with chart id as "myChartId".

 

ChangeWeek function is created. The newly created reference will contain the instance of the chart having the id as "myChartId".

 

And setXMLUrl function is providing new XML data to the same chart.

 

This will affect on the chart.

 

Please find attached demo for your reference with this reply.

 

Hope this helps.

UpdateChartData.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