Reference third level tag value : At : XML Flash / Flex / ActionScript examples


Flash / Flex / ActionScript examples » XML » At »

 

Reference third level tag value


 

package{
  import flash.display.Sprite;
  
  public class Main extends Sprite{
    public function Main(){
        var fruits:XML = <fruits>
                           <fruit color="red">
                             <name>Apple</name>
                           </fruit>
                           <fruit color="orange">
                             <name>Orange</name>
                           </fruit>
                           <fruit color="green">
                             <name>Pear</name>
                           </fruit>
                           <fruit color="red">
                             <name>Watermelon</name>
                           </fruit>
                         </fruits>;
                         
        tracefruits.fruit.(name == "Apple").@color );


    }
  }
}

        



Leave a Comment / Note


 
Verification is used to prevent unwanted posts (spam). .


Flash / Flex / ActionScript examples

 Navioo XML
» At