Tacking this preloader on almost working - what's missing?

Hi
I found a cool preloader tutorial with a free preloader which I added onto my flash project.  I did it by creating a new scene before my project scene, and adding the preloader to it.
The pre loader works fine, and my project all worked fine before I put the preloader on, but now after the preloader finishes, my site's buttons won't work and in Flash CS4 there is a compiler error:
TypeError: Error #1009: Cannot access a property or method of a null object reference.
    at website_fla::MainTimeline/frame2()
Take the preloader scene away, and my site works fine again.
Any idea what I need to do to make them work together?
Cheers
Shaun

Sorry - here it is:
01.import flash.events.ProgressEvent;
02.function update(e:ProgressEvent):void
03.{
04. var percent:Number = Math.floor( (e.bytesLoaded*100)/e.bytesTotal );
05. if(preloaderMC is MovieClip){
06. preloaderMC.gotoAndStop(percent);
07. }
08. if(percent == 100){
09. play();
10. }
11.}
12.loaderInfo.addEventListener(ProgressEvent.PROGRESS, update);
13.// Extra test for IE
14.var percent:Number = Math.floor( (this.loaderInfo.bytesLoaded*100)/this.loaderInfo.bytesTotal );
15.if(percent == 100){
16. nextFrame();
17.}
18.stop();
and here's the page it came from:
http://www.flashmagazine.com/tutorials/detail/how_to_make_a_custom_as3_preloader/
Cheers

Similar Messages

Maybe you are looking for

  • PDF Booklet Printing

    In PDF Booklet printing how do I ensure that center column (for binding) is properly aligned?

  • Reg:Java Server proxies

    Hi ...   I was doing soap to Java Proxy scenario.I have deployed the ear file in the server. Then while executing the sceanrio, in SXMB_MONI i am getting the below error.   <?xml version="1.0" encoding="UTF-8" standalone="yes" ?> - <!--  Inbound Mess

  • BC Forum Module feedback?

    Can anyone share their experience with using the BC forum module? Does it work and would you recommend it? Are there any known problems or issues with BC Forums that I should be aware of?  Any honest input would be appreciated. Thank you!

  • Troubleshooting Ethernet socket

    My Airport card's been giving me fits, so I've tried to connect an ethernet cable to my router, but get no connectoin. The G4 keeps telling me there's no cable connected. When I connect the same cable to another device (Xbox), it works fine. This lea

  • Time Machine - system won't recognise previous backup

    Hi there,      I have just restored my iMac with a clean install of ML. I particularly wanted a clean install as my TM backups were reporting massive and impossible file sizes, so I skipped the Migration Assistant's offer and proceeded as normal. Now