# Load Image in Flash MX 2004

**URL:** <https://forum.kirupa.com/t/load-image-in-flash-mx-2004/156273>\
**Category:** flash\
**Created:** [July 24, 2005, 3:42pm UTC](https://forum.kirupa.com/t/load-image-in-flash-mx-2004/156273 "2005-07-24T15:42:08Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![pixelone](https://avatars.discourse-cdn.com/v4/letter/p/9fc348/32.png) [@pixelone](https://forum.kirupa.com/u/pixelone)\
**Post date:** [July 24, 2005, 3:42pm UTC](https://forum.kirupa.com/t/load-image-in-flash-mx-2004/156273/1 "2005-07-24T15:42:08Z")

</div>

I am able to load xml into my textBox just fine, but I am not getting my image to load.

What I have done so far:

Created MC to hold image: gave it instance name img\_hldr; but how do I tell it in the xml source below to load the image?

function loadXML(loaded) {  
if (loaded) {  
xmlNode = this.firstChild;  
headline = [];  
publisher = [];  
body = [];

```
    total = xmlNode.childNodes.length;
    for (i=0; i&lt;total; i++) {
        
        headline* = xmlNode.childNodes*.childNodes[0].firstChild.nodeValue;
        publisher* = xmlNode.childNodes*.childNodes[1].firstChild.nodeValue;
        body* = xmlNode.childNodes*.childNodes[2].firstChild.nodeValue;
        
    }
    firstImage();
} else {
    content = "file not loaded!";
}

```

}

// Initialize the TextArea component

story\_details.html=true;  
story\_details.wordWrap = true;  
story\_details.multiline = true;  
story\_details.label.condenseWhite =true;

// Load xml content  
fullstory = new XML ();  
fullstory.ignoreWhite = true;  
fullstory.load(“fullstory.xml”);  
fullstory.onLoad = function (success)

```
{
    if (success)
    {
        story_details.text = fullstory;
    }
}
```
