Load image in array
Hi all,
I'd like to load an image with a definiton for each word I type in my search bar.
So far, the text definition is working but I can't load images..
Here's my code :
private var DefinitionArray:Array = [
{label:"Definition1", Text:"It's the text 1", Image: {url:"assets/smiley.jpg"}},
{label:"Definition2", Type:"It's the text 2", Image: {url:"assets/smiley2.jpg"}}];
And when setDisplay is called :
private function setDisplay(e:Event):void{
var fIndex:int = ac.aIndex;
it1.htmlText = "<b>Définition :</b><br /> " + DefinitionArray[fIndex].Type +"<b>image :</b><br /> " + DefinitionArray[fIndex].Image.url;
it1.setTextFormat(titleFormat);
}
Here's what I got as a result :

Do you know what could be the problem ?
Thank you very much,
-------
EDIT
And if I change
DefinitionArray[fIndex].Image.urlby
DefinitionArray[fIndex].ImageI've got this :

