|
|
|
Forum Newbie
      
Group: Forum Members
Last Login: 4/30/2007 5:12:28 AM
Posts: 5,
Visits: 17
|
|
Hi,
Did anyone try to change plotPriceAs from "candlestick" to "line" using setDataXML function without generate 2 sets of XML data ?
Please help.
Regards
|
|
|
|
|
FusionCharts Team
      
Group: Administrators
Last Login: 7/29/2008 12:15:49 PM
Posts: 2,001,
Visits: 474
|
|
Yes - you can do so. But, essentially it'll be a redraw of the chart.
Thanks, Pallav Nadhani FusionCharts Team
|
|
|
|
|
Forum Newbie
      
Group: Forum Members
Last Login: 4/30/2007 5:12:28 AM
Posts: 5,
Visits: 17
|
|
Hi,
if I were to change the attribute "plotPriceAs", am I refer it as "name" like below:
name='plotPriceAs' value='Line'
This is the code I used in the script:
function uptChart(DOMId,x) {
//using updateChartXML method defined in FusionCharts JavaScript class
var chart1 = new FusionCharts("../Charts/CandleStick.swf", "ChartId", "600", "400","0","0");
chart1.setDataURL("Data/Candle6.xml");
if(chart1.setDataXML) {
if(x==2) {
//name='plotPriceAs' value='Line'
chart1.setDataXML("");
} else {
//name='plotPriceAs' value='Candlestick'
chart1.setDataXML("");
}
} else {
alert("setDataXML not supported");
}
chart1.render('chartdiv');
}
I got this error when I execute my script:
Error: chartObj.setDataXML is not a function
Source File: file:///E:/leong%20folder/PowerCharts_Eval/JSClass/FusionCharts.js
Line: 137
Anything wrong with my code ? Please help.
Thanks
|
|
|
|
|
Forum Newbie
      
Group: Forum Members
Last Login: 4/30/2007 5:12:28 AM
Posts: 5,
Visits: 17
|
|
Hi,
Just curious about this:
if the chart data is coming from a XML file, and I only want to change the plotPriceAs value in functional attribute, will setDataXML allow me to change only that small portion or do I need to re-generate the entire XML data structure in javascript as per the sample given in the website ?
Anyone can help ?
|
|
|
|
|
FusionCharts Team
      
Group: Administrators
Last Login: 7/29/2008 12:15:49 PM
Posts: 2,001,
Visits: 474
|
|
You'll need to re-generate the entire XML.
Thanks, Pallav Nadhani FusionCharts Team
|
|
|
|