Hi guys

I'm using AS3 and I'm trying to generate/create some XML data internally from variables.

I found this tutorial online, but the code doesn't seem to work.
http://www.kirupa.com/web/xml/XMLmanageData4.htm

Does anyone know the best way to achieve this?

Any help would be appreciated. Thanks!