satdev Report post Posted March 29, 2010 Hi all, I have a doubt in having both fusion chart and fusion widgets in the same page. I need to have two charts (Line,pie) from fusion charts and a guage charts from fusion widgets to display the total distance. Is this possible to have both the charts in a same page. Please reply me. Thanks Satdev Share this post Link to post Share on other sites
Guest Basundhara Ghosal Report post Posted March 29, 2010 Hi, If you wish to display multiple chart in one page, could you please try rendering each chart in different divs in the HTML page? Ref.- <div id="chart1div" align="center">FusionCharts</div> <script type="text/javascript"> var myChart1 = new FusionCharts("../Charts/Line2D.swf", "myChart1Id", "350", "60", "0", "0"); myChart1.setDataURL("Data/Line2D.xml"); myChart1.render("chart1div"); </script> <div id="chart2div" align="center">FusionWidgets</div> <script type="text/javascript"> var myChart1 = new FusionCharts("../Charts/AngularGuage.swf", "myChart1Id", "350", "60", "0", "0"); myChart1.setDataURL("Data/Angular1.xml"); myChart1.render("chart2div"); </script> Please note, you can use same XML file for all the charts. However, if you wish to specify different XML file for different chart, then please build different XML files and mention the path of the same in the HTML page. Ref.- myChart1.setDataURL("Data/Line2D.xml"); myChart1.setDataURL("Data/Angular1.xml"); Hope this helps. Share this post Link to post Share on other sites
Dusan Report post Posted June 2, 2010 Basundhara Ghosal (3/29/2010)Hi, If you wish to display multiple chart in one page, could you please try renderingeach chartindifferent divs in the HTML page? Ref.- <div id="chart1div" align="center">FusionCharts</div> <script type="text/javascript"> var myChart1 = new FusionCharts("../Charts/Line2D.swf", "myChart1Id", "350", "60", "0", "0"); myChart1.setDataURL("Data/Line2D.xml"); myChart1.render("chart1div"); </script> <div id="chart2div" align="center">FusionWidgets</div> <script type="text/javascript"> var myChart1 = new FusionCharts("../Charts/AngularGuage.swf", "myChart1Id", "350", "60", "0", "0"); myChart1.setDataURL("Data/Angular1.xml"); myChart1.render("chart2div"); </script> Please note, you can use same XML file for all the charts. However, if you wish to specify different XML file fordifferent chart, then please build different XML files and mention the path of the same in the HTML page. Ref.-myChart1.setDataURL("Data/Line2D.xml"); myChart1.setDataURL("Data/Angular1.xml"); Hope this helps. This is not an issue here! If you want to combine charts and widgets in the same HTML page, you have to load two different JSs with the same name: FusionCharts.js. First one is for charts and the second one is for widgets, boat using the same name of the script and the same name for the functions in it, but different signature and processing. So, you can't combine charts and widget together. I'll be glad if I'm wrong here. Share this post Link to post Share on other sites
Dusan Report post Posted June 2, 2010 (just half an hour leather) I tried to put them together with only widgets FusionCharts.js loaded, an it's working well! Share this post Link to post Share on other sites
Sanjukta Report post Posted June 2, 2010 Hi, Glad that your issue is resolved. Thank you for sharing the idea. Happy FusionCharting! Share this post Link to post Share on other sites
fgpx78 Report post Posted October 7, 2010 (edited) Hi, Glad that your issue is resolved. Thank you for sharing the idea. Happy FusionCharting! I'm having the same problem. The two javascripts differs A LOT. The behaveoir is like this - if I use the Widgets FusionCharts.js javascript, I can load data in a column2d chart and an angular gauge both. - if i use the Charts FusionCharts.js it CANNOT load the angulargauge anymore. The problem is that I need the FusionCharts javascript because it contains some function ineed, like the FusionCharts.getObjectReference , to update the data of the graphs and angulargauges in realtime by javascript! How can i fix this? Otherwise, how can I create a code like the following var scoreChart = FusionCharts.getObjectReference("chartId"); scoreChart.setXMLUrl("url_to_file.xml"); var gg= FusionCharts.getObjectReference("gaugeId"); gg.setXMLUrl("url_to_file.xml"); to update a chart and a widget xml data, using the FusionCharts.js file provided with FusionWidget ? In that js file, indeed, there is no FusionCharts.getObjectReference method. I tryed using var scoreChart = FusionCharts("chartId"); but it says "Object doesn't support this property or method" Thank you Edited October 7, 2010 by fgpx78 Share this post Link to post Share on other sites
Guest Basundhara Ghosal Report post Posted October 8, 2010 Hi, Welcome to FusionCharts forum. Please try using the latest JS file(v 3.2.1) as it resolves the issue. Ref.- http://www.fusioncharts.com/puc/ Hope this helps. Share this post Link to post Share on other sites
fgpx78 Report post Posted October 8, 2010 Hi, Welcome to FusionCharts forum. Please try using the latest JS file(v 3.2.1) as it resolves the issue. Ref.- http://www.fusioncharts.com/puc/ Hope this helps. Thank you, the problem is that I'm still evaluating FusionCharts so I am not a registered user. That site (PUC) requires to have an account, or at least to create one with the email associated with a purhcase, how can I obtain that javascript file? Thank you Share this post Link to post Share on other sites
DannyR Report post Posted October 8, 2010 The JS file is also part of the evaluation install. If you downloaded your trial version before yesterday, just get the new one. Share this post Link to post Share on other sites
fgpx78 Report post Posted October 8, 2010 The JS file is also part of the evaluation install. If you downloaded your trial version before yesterday, just get the new one. Thank you, it seem to have solved the problem. Share this post Link to post Share on other sites
Sanjukta Report post Posted October 9, 2010 Hey, You are welcome. Glad that your issue is resolved. Happy FusionCharting! Share this post Link to post Share on other sites