# FlashVars Help

**URL:** <https://forum.kirupa.com/t/flashvars-help/295025>\
**Category:** flash\
**Created:** [August 24, 2009, 2:05pm UTC](https://forum.kirupa.com/t/flashvars-help/295025 "2009-08-24T14:05:24Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![marathon\_ben](https://avatars.discourse-cdn.com/v4/letter/m/439d5e/32.png) [@marathon\_ben](https://forum.kirupa.com/u/marathon_ben)\
**Post date:** [August 24, 2009, 2:05pm UTC](https://forum.kirupa.com/t/flashvars-help/295025/1 "2009-08-24T14:05:24Z")

</div>

Whenever I pass content from an xml file into flash, I prefer to locate that xml file via FlashVars, rather than declare it outright in the FLA.

in AS2 this was as simple as

```auto
xml.load(xmlfile)

```

and

```auto
flashvars.xmlfile = "assets/xml/slideshow.xml";

```

I understand it’s changed for AS3 and found some tutorials that seemed to suggest that the proper method was this:

```auto
var xmlfile:String;
var paramObj:Object = LoaderInfo(this.root.loaderInfo).paramters;
for (xmlfile in paramObj) {
    myFlashVar = String(paramObj[xmlfile]);
}

var my_xml_loader:URLLoader = new URLLoader();
my_xml_loader.load(new URLRequest(xmlfile));
my_xml_loader.addEventListener(Event.COMPLETE, processXML);

```

It’s not working at all however. What am I missing? Thanks!
