I have this code which is a preloader for the loader component on frame 1. However, is there a way to not start playing the timeline yet until the image has been loaded. I have a fade animation in frame 2 and the animation plays while the preloader is loading the image in frame 1. I do not want the timeline to play until the image is loaded. Any help?
myProgressBarListener = new Object();
myProgressBarListener = function (eventObject) {
myProgressBar._visible = false;
};
imageLoader.scaleContent = true;
imageLoader.contentPath = "../images/commercial/images/commercial01.jpg";
myProgressBar.addEventListener("complete", myProgressBarListener);
myProgressBar.mode = "polled";
myProgressBar.source = "imageLoader";
myProgressBar.conversion = "1";
myProgressBar.label = "LOADING %3%%";
myProgressBar.direction = "right";
myProgressBar.labelPlacement = "bottom";