2 Replies Latest reply on Jan 9, 2009 11:54 PM by Wirawannaga

    Multiple Graph from external XML

    Wirawannaga
      Can anybody teach me how to make multiple graph with the data came from external XML for example linegraph.xml . For example user need 3 graph and php generate XML for 3 graph in one file and the flex read and display the chart. So how can i do this because every time i search in internet about it, they will give the data that already [Binding] and not came from the external XML. The question is how the XML format that php to create it so that flex can read in dataprovider . Can anybody teach or give me idea?
        • 1. Re: Multiple Graph from external XML
          rtalton Level 4
          Look at the HTTPService to bring in your XML through a PHP page. Once it is returned to Flex, you just assign it to the dataProvider property of you graph.
          • 2. Re: Multiple Graph from external XML
            Wirawannaga Level 1
            Thanks for the reply... Yes using the HTTP are the right thing. The problem i facing about the xml structure to generate. This example array code :

            dataArrayCollection.addItem(new ArrayCollection([{"x":115, "y":120, label: "Series1.1"},{"x":215, "y":220, label: "Series1.2"},{"x":215, "y":220, label: "Series1.3"}]));
            dataArrayCollection.addItem(new ArrayCollection([{"x":415, "y":420, label: "Series2.1"},{"x":15, "y":520, label: "Series2.2"},{"x":615, "y":620, label: "Series2.3"}]));
            this.dataProvider = dataArrayCollection;

            This array with my code i can make 2 line of graph. But change it into XML format i cannot figure it out. Can u help to design it?