• Content count

  • Joined

  • Last visited

Posts posted by rishin.goswami

  1. Hi,




    Unfortunately the Pie3D chart does not support any styles for the DATAPLOT objects. You can see the list of supported styles at http://www.fusioncharts.com/docs/Contents/ChartSS/Pie3D.html#Objects.




    The charts do not provide any other means of providing information. You can provide additional information for widget types using annotations. Optionally, you can use the absolute layout mode in Flex and put a TextArea component over the chart.

  2. It is necessary to synchronize return events from remote calls and the FCRendered event of the chart.  This is because the methods exposed by the FusionCharts object aren't available until it has fired the FCRenderEvent event. The diagram below is an ideal case where the FCSetDataXML method is invoked after the FCRenderEvent event has fired. For practical cases however, the method may just be invoked before chart has rendered and would thus fail.


    The solution

    The ideal solution would be to create the chart dynamically after the result is received by Flex. Architectural considerations however will not always allow this model. So the task of synchronizing the two events comes into being. In the code below we have done just that.

    Notice that we have decalred a FusionCharts and a HTTPService object in the code. Also, the HTTPService is invoked when the creationComplete event of the application is fired.

    <?xml version="1.0" encoding="utf-8"?>

    <mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" layout="absolute" xmlns:ns1="com.fusioncharts.components.*"





    <ns1:FusionCharts id="fc" FCChartType="Column2D" FCRenderEvent="{onRender()}" />



    <mx:HTTPService id="service" url="someData.xml" result="{onResult(event)}" resultFormat="xml" />  





                            import mx.rpc.events.ResultEvent;                                              



    private var dataXML:String = "";

                            private var hasRendered:Boolean = false;                        


                            private function onResult(e:ResultEvent):void {

                                    dataXML = e.result.toString();




                            private function onRender():void {                              

                                    hasRendered = true;                              




                            private function setData():void {                              

                                    if(hasRendered) {








    The FCRenderEvent of the chart calls upon the onRender method. This method sets the hasRendered flag true and calls upon setData method. Parallely the result event of the HTTPService object invokes the onResult method. This method caches the resultant data and also calls upon setData method.

    The setData method checks if the chart has rendred and then sets the data. Thus no matter which event eventually triggers the setData method first the chart data will always be set to the remote data.