Here I am doing a project to generate flash line graphs using xml data. I prepared every thing ready for this, But only problem I am facing since so many days is from the node values in xml. My mind was blocked with this. I want to read the xml node values into the array in action script. Any help will be greatly appreciated. Here is the code:
Expand|Select|Wrap|Line Numbers
- var fillDataArray=new Array();
- var productInfoArray=new Array();
- var headingXArray=new Array();
- function ck() {
- /* This is the array to be read the values*/
- fillDataArray = [[], [], [], [], []];
- productInfoArray = ['OPEN', 'HIGH', 'LOW', 'CLOSE'];
- headingXArray = ['25-06-07', '26-06-07', '27-06-07', '28-06-07', '29-06-07'];
- myGraph.init(fillDataArray, headingXArray, productInfoArray);
- }
Expand|Select|Wrap|Line Numbers
- <?xml version="1.0" encoding="utf-8"?>
- <CMTICKERDATA>
- <RECORD>
- <CANVASBGCOLOR>E3ECFB</CANVASBGCOLOR>
- <SYMBOL>CONCOR</SYMBOL>
- <SERIES>EQ</SERIES>
- <OPEN>2279</OPEN>
- <HIGH>2675</HIGH>
- <LOW>2126.8</LOW>
- <CLOSE>2206.15</CLOSE>
- <LAST>2200</LAST>
- <PREVCLOSE>2283.65</PREVCLOSE>
- <TOTTRDQTY>12498</TOTTRDQTY>
- <TOTTRDVAL>28124001.55</TOTTRDVAL>
- <TIMESTAMP>1-JUN-2007</TIMESTAMP>
- <DELIVERQTY>8813</DELIVERQTY>
- </RECORD>
- <RECORD>
- <SYMBOL>CONCOR</SYMBOL>
- <SERIES>EQ</SERIES>
- <OPEN>2210</OPEN>
- <HIGH>2265</HIGH>
- <LOW>2151.55</LOW>
- <CLOSE>2172.75</CLOSE>
- <LAST>2170</LAST>
- <PREVCLOSE>2206.15</PREVCLOSE>
- <TOTTRDQTY>3734</TOTTRDQTY>
- <TOTTRDVAL>8288918.55</TOTTRDVAL>
- <TIMESTAMP>4-JUN-2007</TIMESTAMP>
- <DELIVERQTY>2145</DELIVERQTY>
- </RECORD>
- </CMTICKERDATA>