<?xml version="1.0" encoding="utf-8"?>
<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" 
                layout="absolute" xmlns:ns1="com.anychart.*" 
                creationComplete="onCreationComplete();" viewSourceURL="srcview/index.html">
                
    <ns1:AnyChartFlex x="10" y="10" width="690" height="450" id="sampleChart"/>
    
    <mx:Script>
        <![CDATA[
            private function onCreationComplete():void
            {
                var xmlData:XML=<anychart>
                  <charts>
                    <chart plot_type="CategorizedVertical">
                      <data>
                        <series name="Product Sales" type="Bar">
                          <point name="2004" y="63716" />
                          <point name="2005" y="72163" />
                          <point name="2006" y="94866" />
                          <point name="2007" y="56866" />
                          <point name="2008" y="19000" />
                        </series>
                      </data>
                      <chart_settings>
                          <title>
                              <text>ACME Corp. Sales</text>
                          </title>
                          <axes>
                              <x_axis>
                                  <title>
                                      <text>Year</text>
                                  </title>
                              </x_axis>
                              <y_axis>
                                  <title>
                                      <text>Sales (USD)</text>
                                  </title>
                              </y_axis>
                          </axes>
                      </chart_settings>
                    </chart>
                  </charts>
                </anychart>;
                
                sampleChart.anychartXML=xmlData;
            }
        ]]>
    </mx:Script>
</mx:Application>