# Using XML

**URL:** <https://forum.kirupa.com/t/using-xml/269753>\
**Category:** Uncategorized\
**Created:** [September 1, 2008, 3:55am UTC](https://forum.kirupa.com/t/using-xml/269753 "2008-09-01T03:55:54Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![alliev](https://avatars.discourse-cdn.com/v4/letter/a/d6d6ee/32.png) [@alliev](https://forum.kirupa.com/u/alliev)\
**Post date:** [September 1, 2008, 3:55am UTC](https://forum.kirupa.com/t/using-xml/269753/1 "2008-09-01T03:55:54Z")

</div>

Hey,

I’m trying to load some XML and then use it to setup some constants to use elsewhere but really don’t know how to access the XML once it is loaded.

```auto

var xmlLoader:URLLoader = new URLLoader();
var xmlData:XML = new XML();

xmlLoader.addEventListener(Event.COMPLETE, LoadXML);

xmlLoader.load(new URLRequest('SelectorConstants.xml'));

function LoadXML(e:Event):void {
    xmlData = new XML(e.target.data);
}

```

This loads my xml fine and I can trace it within the LoadXML function. However, I have no idea how to do anything useful with it - such as assign various parts to constants. How can I access xmlData elsewhere?

I would be really grateful if anyone can point me in the right direction here.

Thanks. Allie
