rluengo Report post Posted November 26, 2009 Hello, We have just bought dragnode.swf and it is still saying that the object does not support the getXMLData method. Please help, we really do need to use the method as soon as possible. Kind regards, Roberto Luengo Share this post Link to post Share on other sites
rluengo Report post Posted November 26, 2009 By the way... I have been reading the forum and already did what they advice in the topics. It is running in a localhost server. The New FusionCharts last parameter is set to 1. Share this post Link to post Share on other sites
rluengo Report post Posted November 26, 2009 Here is the code... Just in case someone need it: To render the chart: var obj = $("content_scroll_content"); var chartwidth = obj.style.pixelWidth; var chart = new FusionCharts("includes/fusioncharts/DragNode.swf", "fusiondemo", (chartwidth-16), screen.height, "0", "1"); chart.setTransparent(true); chart.setDataURL("includes/fusioncharts/DragNode1.xml"); chart.render("chartdiv"); And to get the xml: var ourChart = getChartFromId("chartdiv"); var xmlRtn = ourChart.getXMLData(); I have already test it in a remote server too with the same result Share this post Link to post Share on other sites
Guest Basundhara Ghosal Report post Posted November 26, 2009 Hi, Could you try it using the following method:- chart.setDataXML("Your XML codes"); Hope this helps. Share this post Link to post Share on other sites
rluengo Report post Posted November 27, 2009 (edited) Hi, I just tried the method you proposed (setDataXML) with the same result. Just to be clear I need to extract the xml, not set it... but tried anyway just to see if I receive the same error. Thank you for the try Edited November 27, 2009 by Guest Share this post Link to post Share on other sites
Guest Basundhara Ghosal Report post Posted November 27, 2009 Hi, Thanks for your appreciation. Could you please try customizing your code using JavaScript in order to extract your XML codes? Ref.- <div id="chart1div"> FusionCharts </div> <script language="JavaScript"> var chart1 = new FusionCharts("../../FusionCharts/Column3D.swf", "chart1Id", "400", "300", "0", "1"); chart1.setDataXML("<chart><set label='A' value='10' /><set label='B' value='11' /></chart>"); chart1.render("chart1div"); </script> Thereafter, you can invoke the getXML() method of the chart object to get the XML codes. <SCRIPT LANGUAGE="Javascript" SRC="../../FusionCharts/FusionCharts.js"></SCRIPT> <SCRIPT LANGUAGE="JavaScript"> function getChartXML(){ //Get chart from its ID var chartToPrint = getChartFromId("chart1Id"); alert(chartToPrint.getXML()); } Also, please take a look into the link below:- http://www.fusioncharts.com/docs?/JS_getXML.html Hope this helps. Share this post Link to post Share on other sites
rluengo Report post Posted November 29, 2009 Hi Basundhara Ghosal, I tried this code without success Here is the code: function showChart() { var obj = $("content_scroll_content"); var chartwidth = obj.style.pixelWidth; var chart = new FusionCharts("includes/fusioncharts/DragNode.swf", "chart1Id", (chartwidth-16), screen.height, "0", "1"); chart.setTransparent(true); chart.setDataURL("includes/fusioncharts/DragNode1.xml"); chart.render("chart1div"); } function getChartXML() { var ourChart = getChartFromId("chart1Id"); var xmlRtn = ourChart.getXML(); } The chart shows but I am unable to get the XML from it. Any other ideas? I am testing in a apache/php server in localhost and in a remote server as well. Kind regards, Roberto Luengo Share this post Link to post Share on other sites
rluengo Report post Posted November 29, 2009 By the way. The editor I use to debug javascript is showing me that the chart object do not have that method in the list (getXML, getXMLData, etc). Could it be that my version is not the one it is supposed? I was checking the files received when buying the oem license and found that the fusioncharts.js file is smaller and older (v1.2 Share this post Link to post Share on other sites
rluengo Report post Posted November 29, 2009 (edited) Another comment, I am using fusioncharts.js and dragnode.swf. We bought only the dragnode.swf chart which is the only one we need, but the .zip file received had the following : Empty Contents folder Empty code folder Empty gallery ONLY fusioncharts.js, in the evaluation package there was another file of name "FusionChartsExportComponent.js" which I do not believe we need. And of course the source code (which I expect not to use) and the swf. All this empty folders plus the version numbers is making me think that maybe the package is not complete. What do you think? Is this the problem? Edited November 29, 2009 by Guest Share this post Link to post Share on other sites
rluengo Report post Posted November 30, 2009 Any ideas? I have tried restoring the evaluation .js without success as advised by Rajroop Share this post Link to post Share on other sites
FusionCharts Support Report post Posted November 30, 2009 Hi, Could you please send us a live URL so that we can debug live and let us know. getXMLData() is a valid function for DragNode chart. And there should not be any issue with FusionCharts.js. You might update to the latest version from http://www.fusioncharts.com/PUC. Share this post Link to post Share on other sites
Guest Rajroop Report post Posted December 1, 2009 Hello Roberto, I come with good news. The issue was not with the FusionCharts.js file, as we had thought earlier. We have tested the SWF that you had sent us. After a bit of debugging, we got to the bottom of this issue. You would have to use the getXMLData() method to retrieve the data from the chart. The registerWithJs has to be enabled for this, as you know. Please find the attached ZIP file which contains a HTML file. I have sent you a mail along with the complete solution. I hope this helps. Do let us know if you have any more queries concerning this. :hehe: DragNode1.zip Share this post Link to post Share on other sites