XML text in a String into an actual XML object, whereas a cast would fail. : Bracket syntax : XML Flash / Flex / ActionScript examples


Flash / Flex / ActionScript examples » XML » Bracket syntax »

 

XML text in a String into an actual XML object, whereas a cast would fail.


 


package{
  import flash.display.Sprite;
  
  public class Main extends Sprite{
    public function Main(){
        var myXml:XML = XML("<root><party><time>Now</time><location>Here</location></party></root>");
        trace(myXml.party[0].time)//Now
    }
  }
}

        



Leave a Comment / Note


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


Flash / Flex / ActionScript examples

 Navioo XML
» Bracket syntax