Natty,
Try something like this:loader.contentLoaderInfo.addEventListener(IOErrorE vent.IO_ERROR, imgLoadErrorMethod);
Hi Robert!!Thanks, I tried with the following code:Now I want to ask u how can I set a value to the MiniSearch widget textbox from the SearchWidget..Can u help me with this?
public function IOErrorEventHandler(imgx:String):void {
var loader:Loader = new Loader();
loader.contentLoaderInfo.addEventListener (Event.COMPLETE, onComplete);
loader.contentLoaderInfo.addEventListener(IOErrorEvent.IO_ERROR, ioErrorHandler);
var request:URLRequest = new URLRequest(imgx);
loader.load(request);
}
private function onComplete (evt : Event) : void
{
infoImage.source = "Images/" + infoData.title + ".jpg";
infoImage.height = 150;
infoImage.width = 190;
infoImage.visible = true;
infoImage.includeInLayout = true;
}
private function ioErrorHandler(event:IOErrorEvent):void {
infoImage.visible = false;
infoImage.includeInLayout = false;
}