9 Replies Latest reply on Jun 13, 2007 11:34 AM by netsped

    Preloader problem

    netsped
      Im making an intro with a preloader bar, I have included a background and my intention is to make the web page visible until it is fully loaded. But when it loads about 40% the background dissapears and the webpage is visible and the preloader stays there until it loads 100%. What will I have to add so the background dissapears at 100% loaded.

      Thanks
        • 1. Re: Preloader problem
          kglad Adobe Community Professional & MVP
          change its _visible (as2) property when loading is complete.
          • 2. Re: Preloader problem
            netsped Level 1
            quote:

            Originally posted by: kglad
            change its _visible (as2) property when loading is complete.


            Hi dude, sorry honestly Im a newbie and I can not figure out where is the problem. Can I send you the actionscript that I wrote so you can help me....
            thanks

            • 3. Re: Preloader problem
              FlashForumName
              All you have to do is:

              backgroundObjectName._visible = false;

              in the event that your loader completes.
              • 4. Re: Preloader problem
                Damon Edwards Level 3
                you can do something like this
                • 5. Preloader problem
                  netsped Level 1
                  Thanks for your help, I still dont know how to do this. I got the idea from a lynda.com tutorial, here is the actions that I have applied:

                  var myMCL:MovieClipLoader = new MovieClipLoader();
                  var myListener:Object = new Object();

                  myMCL.addListener(myListener);

                  myListener.onLoadProgress = function(target_mc:MovieClip, bytesLoaded:Number, bytesTotal:Number) {
                  var loaded:Number = Math.round((bytesLoaded/bytesTotal) * 100);
                  progressBar.gotoAndStop(loaded);
                  }

                  myListener.onLoadInit = function (target_mc:MovieClip) {
                  progressBar._visible = false;
                  logo._visible = false;
                  }

                  myListener.onLoadStart = function (target_mc:MovieClip) {
                  progressBar._visible = true;
                  logo._visible = true;
                  }

                  myMCL.loadClip("xxxxx.swf","container");


                  Maybe you can tell me where is the error or where do I need to add something, the background is "logo" and the progressbar is "progressBar". Thanks
                  • 6. Re: Preloader problem
                    kglad Adobe Community Professional & MVP
                    you can't load an html file. what's that about?
                    • 7. Re: Preloader problem
                      netsped Level 1
                      quote:

                      Originally posted by: kglad
                      you can't load an html file. what's that about?


                      No Im not loading an html file, I have a swf embedded to a html file but when I copy paste the code here I add the html extension but it should by a swf, sorry. So what is wrong with the actions??? Please help

                      • 8. Re: Preloader problem
                        kglad Adobe Community Professional & MVP
                        nothing is wrong with that code, then.

                        the frame that contains that code only executes once, correct?
                        • 9. Re: Preloader problem
                          netsped Level 1
                          quote:

                          Originally posted by: kglad
                          nothing is wrong with that code, then.

                          the frame that contains that code only executes once, correct?


                          What do you mean by that? You mean if I have a stop() in the frame??

                          Please help me Im new to preloaders!!!