2 Replies Latest reply on Aug 19, 2009 10:34 PM by Flex harUI

    How to use e4x to extract complex data like this ?

    CakeBunny

      The xml object structure like the following :

       

      <TEXTFORMAT LEADING="2">
          <P ALIGN="LEFT">
              <FONT FACE="Verdana" SIZE="16" COLOR="#0B333C" LETTERSPACING="0" KERNING="0">
                 First Item
                            <FONT SIZE="10">
                           Second Item
                            </FONT>
              </FONT>
          </P>
      </TEXTFORMAT>

       

      this is the htmltext from richTextEditor , I want every font size = 16 value to be a tree label .

       

      So my question is : how can I extract "First Item "? I Know it's easy to exract the "second Item" , like P.FONT.FONT ,

      BUT , I use P.FONT, instead of get "First Item" I get  :

       

      <FONT FACE="Verdana" SIZE="16" COLOR="#0B333C" LETTERSPACING="0" KERNING="0">
                 First Item
                            <FONT SIZE="10">
                           Second Item
                            </FONT>
              </FONT>

       

       

      I only want to extract "First Item" out of this XML block , Any Ideas ?