Can Anyone help me with this??? I want my preloader to play without having to click view and simulate download. What do I need to change/add????

stop();

this.loaderInfo.addEventListener(ProgressEvent.PRO GRESS, onLoading);
this.loaderInfo.addEventListener(Event.COMPLETE, onComplete);

function onLoading(evt:ProgressEvent):void {
var loaded:Number = evt.bytesLoaded / evt.bytesTotal;
percent_txt.text = (loaded*100).toFixed(0) + "%";
bar.scaleX = loaded
};

function onComplete(event:Event):void {
this.loaderInfo.removeEventListener(ProgressEvent. PROGRESS, onLoading);
this.loaderInfo.removeEventListener(Event.COMPLETE , onComplete);
gotoAndStop(2);
};