# Moviclip starts playing before preloader finishes

**URL:** <https://forum.kirupa.com/t/moviclip-starts-playing-before-preloader-finishes/237231>\
**Category:** flash\
**Created:** [August 28, 2007, 12:12pm UTC](https://forum.kirupa.com/t/moviclip-starts-playing-before-preloader-finishes/237231 "2007-08-28T12:12:24Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![taobabyluv](https://avatars.discourse-cdn.com/v4/letter/t/e95f7d/32.png) [@taobabyluv](https://forum.kirupa.com/u/taobabyluv)\
**Post date:** [August 28, 2007, 12:12pm UTC](https://forum.kirupa.com/t/moviclip-starts-playing-before-preloader-finishes/237231/1 "2007-08-28T12:12:24Z")

</div>

This is probably a quick and easy thing. The movieclip that is supposed to get played after preloading actually starts before clip is fully loaded. You can see the problem in action here: [www.stopandwonder.com](http://www.stopandwonder.com).

Here’s the code that goes with the preloader.

```auto
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;
}

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

myMCL.loadClip("images/slideshowFinal.swf", "container");

```

It’s just a 100 frame movieclip preloading graphic.

Anyway, I appreciate any help. Thanks.
