Preloader woes

Hai,

I’m using this here preloader… :

this.loaderInfo.addEventListener(ProgressEvent.PROGRESS, onRootLoaderProgress);
this.loaderInfo.addEventListener(Event.COMPLETE, onRootLoaderComplete);

function onRootLoaderProgress (event:ProgressEvent):void
{
	   var lb:int = event.bytesLoaded;
	   var ltl:int = event.bytesTotal;
	   var ratio:int = lb/ltl*100;
	   lpc0.text = String(ratio)+"%";
	   lbar0.scaleX = ratio/100;
	   lpc0.x = (1024/100)*ratio- 230;
	   trace(ratio);
}
function onRootLoaderComplete (event:Event):void
{
	   var lb:int = event.target.bytesLoaded;
	   var ltl:int = event.target.bytesTotal;
	   var ratio:int = lb/ltl*100;
	   lpc0.text = String(ratio)+"%";
	   lbar0.scaleX = ratio/100;
	   if(ratio>=100)
	   {
			   gotoAndStop(5);
	   }
}

but when i stick this online with the rest of my movie, it sometimes just hangs on 100%. I don’t see anything wrong with my code so i’m wondering if another set of eyes would be able to spot what’s wrong.