Trevor
Members-
Content count
5 -
Joined
-
Last visited
About Trevor
-
Rank
Forum Newbie
-
I'm trying to use the Pyramid FusionWidget within Flash (a .fla project). I've followed the tutorial (though this was for a FusionChart rather than a FusionWidget), but I'm unable to get it to work. Please see my ActionScript below: //You first need to include the following two files in your movie. //These two files contain pre-loading functions and application //messages for the chart. //Note: If you're loading multiple charts in your Flash movie, you //do NOT need to include these files for each each. You can put these //lines in the main timeline, so that it gets loaded only once. #include "com/fusioncharts/includes/LoadingFunctions.as" #include "com/fusioncharts/includes/AppMessages.as" //To create the chart, you now need to import the Class of the //chart which you want to create. All charts are present in the package //com.fusioncharts.core.charts (Download Package > SourceCode folder) //If you're using multiple charts, you can import all the requisite //chart classes in the main timeline of your movie. That ways, you //wouldn't have to import the chart classes everytime you wish to use. import com.fusioncharts.core.charts.PyramidChart.as; // ------------- XML Data for the charts -------------- // //Data for chart 1 var strXML1:String = "<chart showBorder='0' bgAlpha='0,0' palette='1' caption='Hourly Working Rate' numberPrefix='>"; //Add simple data for demo. strXML1 = strXML1+"<set name='John' value='32' />"; strXML1 = strXML1+"<set name='Mary' value='65' />"; strXML1 = strXML1+"<set name='Michelle' value='29' />"; strXML1 = strXML1+"<set name='Cary' value='43' />"; strXML1 = strXML1+"</chart>"; var xmlData1:XML = new XML(strXML1); //Data for Chart 2 var strXML2:String = "<chart showBorder='0' bgAlpha='0,0' palette='1' caption='Hours Worked Last week' canvasPadding='20'>"; //Add simple data for demo. strXML2 = strXML2+"<set name='John' value='49' />"; strXML2 = strXML2+"<set name='Mary' value='34' />"; strXML2 = strXML2+"<set name='Michelle' value='61' />"; strXML2 = strXML2+"<set name='Cary' value='40' />"; strXML2 = strXML2+"</chart>"; var xmlData2:XML = new XML(strXML2); // --------------------------------------------------- // // -------------- Actual Code to create the chart ------------// //Create movie clips required for both the charts var chartContainer1MC:MovieClip = this.createEmptyMovieClip("ChartHolder1", 1); var chartContainer2MC:MovieClip = this.createEmptyMovieClip("ChartHolder2", 2); //Now, instantiate the charts using Constructor function of the chart. var chart2:PyramidChart.as = new PyramidChart.as(chartContainer2MC, 1, 380, 325, 20, 15, false, "EN", "noScale"); //Convey the XML data to chart. chart1.setXMLData(xmlData1); chart2.setXMLData(xmlData2); //Draw the charts chart1.render(); chart2.render(); //Stop stop(); I get the following compiler error: Location: Scene=Scene 1, layer=Layer1, frame=1, Line=43 Description: The class or interface 'PyramidChart.as' could not be loaded The "com" folder is in the same folder as the .fla and .swf. The .fla file is attached Please help! Thanks
-
I copied the MultiPie.xml file to the "FusionCharts" folder and changed myChart.setXMLUrl("data.xml") to myChart.setXMLUrl("MultiPie.xml") in the HTML file (attached) which now reads: <html> <head> <title>My First chart using FusionCharts</title> <script type="text/javascript" src="../FusionCharts/FusionCharts.js"> </script> </head> <body> <div id="chartContainer">FusionCharts will load here!</div> <script type="text/javascript"> var myChart = new FusionCharts("../FusionCharts/MultiLevelPie.swf", "myChartId", "400", "300", "0", "1" ); myChart.setXMLUrl("MultiPie.xml"); myChart.render("chartContainer"); </script> </body> </html> But unfortunately it still doesn't display the chart. Any ideas why? Thanks Manhattan_Organogram.html MultiPie.xml
-
The XML (also attached) reads: <?xml version="1.0" encoding="utf-8"?> - <chart palette="2" piefillAlpha="34" pieBorderThickness="3" hoverFillColor="FDCEDA" pieBorderColor="FFFFFF" baseFontSize="9" useHoverColor="1" showLabels="1" caption="Organization Chart"> - <category label="CEO" hoverText="<B><U>Chief Technology Officer</U></B><BR>Mr. Lucas Smith<BR>Joined: 1988<BR>More details can come here..." fillColor="DBFF6C" link="n-http://www.InfoSoftGlobal.com/FusionCharts?Details=CTO"> - <category label="CTO" hoverText="<B><U>Chief Technology Officer</U></B><BR>Mr. Ed Harley<BR>Joined: 1988<BR>More details can come here..." fillColor="DBFF6C" link="n-http://www.InfoSoftGlobal.com/FusionCharts?Details=CTO"> - <category label="Proj. Manager" hoverText="<B><U>Project Manager</U></B><BR>Mr. Daniel Edwards"> <category label="Design" hoverText="<B><U>Design Team</U></B><BR><LI>Akhil Dhanuka<BR>Atrayee<BR>Samit Basak</LI>" /> <category label="Coding" hoverText="<B><U>Coding Team</U></B><BR><LI>Sanket Kumar<BR>Folko<BR>George Baker<BR>Andrew Hall<BR>Chris Schofield </LI>" /> <category label="Validate" hoverText="<B><U>Validation Team</U></B><BR><LI> Raju Sharma <BR>Ravi Srivastav </LI>" /> </category> - <category label="Q & A Manager" hoverText="<B><U>Q & A Manager</U></B><BR>Mr. Lee Chong"> <category label="Testing Team" hoverText="<B><U>Testing Team</U></B><BR><LI> Nik Arora <BR>Jee Chou</LI>" /> </category> - <category label="Architect" hoverText="<B><U>System Architecture Manager</U></B><BR>Mr. Rajiv Kumar"> <category label="Study" hoverText="<B><U>System Requirement Study Team</U></B><BR><LI> Raju Sharma <BR>Ravi Srivastav </LI>" /> <category label="Design" hoverText="<B><U>Design Team</U></B><BR><LI> Raju Sharma <BR>Ravi Srivastav <BR>Robin Smith <BR>Harry Tofel </LI>" /> </category> </category> - <category label="CFO" hoverText="<B><U>Chief Financial Officer</U></B><BR>Mr. John Smith<BR>Joined: 1987<BR>More details can come here..." fillColor="FBE299" link="n-http://www.InfoSoftGlobal.com/FusionCharts?Details=CFO"> - <category label="Payables" hoverText="Accounts Payable Team"> <category label="Salary" hoverText="Team for salary accounts maintenance and upkeep" /> <category label="Purchase" hoverText="Team for accounting of purchase of S/w and goods" /> <category label="Other" hoverText="Other Payments" /> </category> - <category label="Receivables" hoverText="Accounts Receivables Team"> <category label="SW1" hoverText="Online Software Receipts Accounts" /> <category label="SW2" hoverText="Physical Software Receipts Accounts" /> <category label="SER1" hoverText="Services Collection" /> <category label="SER2" hoverText="Services Collection (Physical)" /> <category label="OTR" hoverText="Subscription and Other Collections" /> </category> </category> - <category label="CIO" hoverText="<B><U>Chief Information Officer</U></B><BR>Mr. David Brown<BR>Joined: 1992<BR>More details can come here..." fillColor="DAEDFC" link="n-http://www.InfoSoftGlobal.com/FusionCharts?Details=CIO"> - <category label="PR" hoverText="PR Team"> <category label="Packaging" hoverText="Packaging Staff" /> <category label="Inv Rel." hoverText="Investor Relations Upkeep" /> <category label="Marketing" hoverText="Marketing & Sales" /> </category> - <category label="HR" hoverText="HR Team"> <category label="Selection" hoverText="Selection of Candidates" /> <category label="Deploying" hoverText="Deploying at required site" /> </category> </category> </category> - <styles> - <definition> <style name="myHTMLFont" type="font" isHTML="1" /> <style name="captionFont" type="font" size="16" /> </definition> - <application> <apply toObject="TOOLTIP" styles="myHTMLFont" /> <apply toObject="CAPTION" styles="captionFont" /> </application> </styles> </chart> Thanks data.xml
-
Thanks that worked! The chart that I'm really interested in is the multi-level pie chart. I pasted the data from Gallery\Data\MLPie1.xml into data.xml and changed "Column3D.swf" to "MultiLevelPie.swf" and copied MultiLevelPie.swf into the folder in the hope that this would result in a working example, but it unfortunately didn't. My HTML (attached) now reads: <html> <head> <title>My First chart using FusionCharts</title> <script type="text/javascript" src="../FusionCharts/FusionCharts.js"> </script> </head> <body> <div id="chartContainer">FusionCharts will load here!</div> <script type="text/javascript"> var myChart = new FusionCharts("../FusionCharts/MultiLevelPie.swf", "myChartId", "400", "300", "0", "1" ); myChart.setXMLUrl("data.xml"); myChart.render("chartContainer"); </script> </body> </html> What should it be? Thanks Manhattan_Organogram.html
-
I'm having the same issue. I tried to follow the tutorial exactly. My HTML (attached): <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR...ransitional.dtd"> <html> <head> <title>My First chart using FusionCharts</title> <script type="text/javascript" src="FusionCharts.js"> </script> </head> <body> <div id="chartContainer">FusionCharts will load here!</div> <script type="text/javascript"><!-- var myChart = new FusionCharts( "Column3D.swf", "myChartId", "400", "300", "0", "1" ); myChart.setXMLUrl("Data.xml"); myChart.render("chartContainer"); // --> </script> </body> </html> My XML: <?xml version="1.0" encoding="utf-8"?> <chart caption='Weekly Sales Summary' xAxisName='Week' yAxisName='Sales' numberPrefix='$'> <set label='Week 1' value='14400' /> <set label='Week 2' value='19600' /> <set label='Week 3' value='24000' /> <set label='Week 4' value='15700' /> </chart> jquery.min.js, FusionCharts.js, FusionCharts.HC.PowerCharts.js, FusionCharts.HC.js, Column3D.swf, Spline.swf, data.xml, weekly-sales.html are all in the " Learning Fusion Charts\MyFirstChart\FusionCharts" folder Please help! I'm sure there are many others users evaluating your product & not purchasing it due to this issue Thanks