bdcraigfl

Add Node Xml

Recommended Posts

I am creating a Drag Node diagram. Instead of entering node location etc.. into the xml I want to be able to perform the Add Node using the browser and saving the changes. I tried using the example in the documentation under the section "Getting data using Javascript" but was unsuccessful displaying the xml. Here is my html :

 

<html>

<head>

<script language="JavaScript" src="../FusionCharts/FusionCharts.js"></script>

</head>

<body bgcolor="#ffffff">

<div id="chartdiv" align="center">The chart will appear within this DIV. This text will be replaced by the chart.</div>

<script type="text/javascript">

var myChart = new FusionCharts("../FusionCharts/DragNode.swf", "myChartId", "1100", "700", "0", "1");

myChart.setXMLUrl("roadmap_creation.xml");

myChart.render("chartdiv");

 

function getChartXml(){

//Get chart from its ID

var charRef = FusionCharts("myChartId");

var xmlRtn = charRef.getXMLData();

alert(xmlRtn);

}

</script>

<center><input type='button' value='Retrieves updated XML' onClick='javascript:getChartXml();'></center>

</body>

</html>

 

example of my xml:

 

<chart caption='LT2 Roadmap' palette='2' xAxisMinValue='0' xAxisMaxValue='100' yAxisMinValue='0' yAxisMaxValue='100' is3D='1' showFormBtn='1' formAction='process.jsp' viewMode='0' numDivLines='3' divLineColor='000000' divLineThickness='3' alternateHGridColor='A9A9A9' canvasBgColor='D3D3D3' rotateYAxisName='0'>

<dataset>

</dataset>

<connectors color='FF0000' stdThickness='5'>

</connectors>

<categories>

<category x='1' label='Nov 10' lineDashed='1' showVerticalLine='0' showLabel='1' toolText='Nov 10'/>

<category x='16' label='Dec 10' lineDashed='1' showVerticalLine='1' showLabel='1' toolText='Dec 10'/>

<category x='32' label='Jan 11' lineDashed='1' showVerticalLine='1' showLabel='1' toolText='Jan 11'/>

<category x='48' label='Feb 11' lineDashed='1' showVerticalLine='1' showLabel='1' toolText='Feb 11'/>

<category x='64' label='Mar 11' lineDashed='1' showVerticalLine='1' showLabel='1' toolText='Mar 11'/>

<category x='80' label='Apr 11' lineDashed='1' showVerticalLine='1' showLabel='1' toolText='Apr 11'/>

<category x='99' label='May 10' lineDashed='1' showVerticalLine='0' showLabel='1' toolText='May 10'/>

</categories>

<TrendLines>

<line startValue='87' color='000000' displayvalue='LT2 Component' isTrendZone='1'/>

<line startValue='62' color='000000' displayvalue='CTIA' isTrendZone='1'/>

<line startValue='37' color='000000' displayvalue='L-TESS' isTrendZone='1'/>

<line startValue='12' color='000000' displayvalue='CTC-IS' isTrendZone='1'/>

</TrendLines>

</chart>

 

 

 

The alert box is empty. Any help would be appreciated.

 

Share this post


Link to post
Share on other sites
Guest Angie

Dear User,

 

We are delighted to announce that PowerCharts is now ready for your iPads and iPhones too. We have just released PowerCharts v3.2. Starting v3.2, PowerCharts has HighCharts embedded within it, and offers both Flash and JavaScript (HTML5) charting . The Flash charts are displayed on a majority of devices and the JavaScript charts on devices that do not support Flash, all of it without writing a line of code.

 

Automatic rendering of JavaScript charts on devices (like iPad and iPhone) where Flash player is not supported.

 

5 new chart types:

 

Heat Map Chart

 

Box and Whisker Chart

 

Step Line Chart

 

Error Line Chart

 

Error Scatter Chart

 

 

* Support for JSON data format.

 

* Support for LinkedCharts, where a single data source controls multiple charts.

 

* Interactive legends in charts allow selective showing/hiding of data series.

 

* Legends now support icons for each data series.

 

* Better management of labels on charts.

 

* Labels now have an auto rendering mode to prevent them from overlapping, the chart selects the best display mode depending on the length of the labels and the width of the chart.

 

* Long labels are truncated, with ellipses appended to the truncated end of each label, and a tooltip bearing the completed label text is displayed when the user hovers over a truncated label.

 

* Support for line breaks and wrapping in all text elements including: caption, sub caption, X-axis title, Y-axis title, Labels and tooltips.

 

* In Line charts, data values can now be positioned either above or below the dataplots. Automatic positioning of data values is also supported.

 

* In Step-line charts dataplots can be joined using vertical lines.

 

* Custom alignment of caption and sub caption using STYLES.

 

* Advanced print management using JavaScript.

 

* Additional options for efficient event handling using JavaScript.

 

* Support for dynamic update of chart properties using JavaScript(barring select scatter and drag charts).

 

* Charts now support % based sizes along with dynamic resizing (barring select scatter and drag charts).

 

 

Learn more about everything new in PowerCharts v3.2 at : http:/ www.fusioncharts.com/PowerCharts/

 

We would love to hear from you at: http://www.fusioncharts.com/contact/

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