0 Replies Latest reply on Sep 23, 2009 12:38 PM by ajc2357

    XMLList filter: 1131 Error

    ajc2357

      Hi all,

       

      I created an XMLList from an external XML file in flex and have successfully used it as a dataProvider in a series of charts.  What I'd like to do is create a secondary variable to ultimately show a subset of the original dataset.  For example, all of my charts currently show all 12 countries collected in my XML file.  I want to create a new variable to show only the countries in Asia, for example.

       

      What is wrong with the following code?  When I enter it I get the "1131: Classes must not be nested" error...

       

              [Bindable] public var allData:XMLList;
             
              private var asiaData:XMLList = allData.(region="Asia");

       

      The structure of my xml file is as follows:

       

      <data>
          <Location>
              <regrank>1</regrank>
              <country>United States</country>
              <region>United States</region>
              <reg08>113984</reg08>
              <reg09>113627</reg09>
              <regp>-0.3</regp>
              <regn>-357</regn>
              <ex08>101721</ex08>
              <ex09>101526</ex09>
              <exp>-0.2</exp>
              <exn>-195</exn>
          </Location>

      </data>