# Using XML in Flash CS3/AS3 - Output XML to Stage

**URL:** https://forum.kirupa.com/t/using-xml-in-flash-cs3-as3-output-xml-to-stage/286136
**Category:** flash
**Created:** [April 10, 2009, 4:20pm UTC](https://forum.kirupa.com/t/using-xml-in-flash-cs3-as3-output-xml-to-stage/286136 "2009-04-10T16:20:04Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![golfman76](https://avatars.discourse-cdn.com/v4/letter/g/898d66/32.png) [@golfman76](https://forum.kirupa.com/u/golfman76)
#### Post date: [April 10, 2009, 4:20pm UTC](https://forum.kirupa.com/t/using-xml-in-flash-cs3-as3-output-xml-to-stage/286136/1 "2009-04-10T16:20:04Z")

</div>

As a follow up to learning the XML in AS3 from this Tutorial, [http://www.kirupa.com/developer/flashcs3/using\_xml\_as3\_pg1.htm](http://www.kirupa.com/developer/flashcs3/using_xml_as3_pg1.htm), wanted to know how to create text boxes dynamically for each element to display on the stage. Want to add space to the y axis to drop one on top of the other, so they don’t just layer on top of each other.

```auto

for (var i:int = 0; i < authorList.length(); i++) { 
var authorElement:XML = authorList*;         
trace(authorElement);
-- // instead of trace, create a text field to output the authorList        
-- // this doesn't work, but was my thought at how it might work.
        var myText:TextField = new TextField();
        myText.autoSize;
        myText.text = authorElement;
        addChild(myText);
  } 

```

Pointers or alternate suggestions appreciated.
