Hey, I'm new to the forums and I have problems with Flash that i just cant fix. I have this error that keeps telling me how "The class or interface 'Event' could not be loaded. The error is on the 5th line of the code:


1 stop();
2
3 addEventListener(Event.ENTER_FRAME, preLoad);
4
5 function preLoad(e:Event):void{
6 var bytestoLoad:Number = loaderInfo.bytesTotal;
7 var numberLoaded:Number = loaderInfo.bytesLoaded;
8 if(bytestoLoad == numberLoaded){
9 removeEventListener(Event.ENTER_FRAME, preLoad);
gotoAndStop(2);
} else {
_root.preLoader.preLoaderFill.scaleX = numberLoaded/bytestoLoad;
_root.preLoader.bytesPercent.text = Math.floor(numberLoaded/bytestoLoad*100) + "%";
}
}

I know that the code is for AS3 but I cant switch to AS3 atm and I need the same code, but for AS2. So, can anyone convert this for me? Thanks in advance