# Adapt Kirupa Tutorial to show preload status

**URL:** <https://forum.kirupa.com/t/adapt-kirupa-tutorial-to-show-preload-status/240280>\
**Category:** flash\
**Created:** [October 1, 2007, 4:43pm UTC](https://forum.kirupa.com/t/adapt-kirupa-tutorial-to-show-preload-status/240280 "2007-10-01T16:43:21Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![mcrodrigues](https://avatars.discourse-cdn.com/v4/letter/m/c67d28/32.png) [@mcrodrigues](https://forum.kirupa.com/u/mcrodrigues)\
**Post date:** [October 1, 2007, 4:43pm UTC](https://forum.kirupa.com/t/adapt-kirupa-tutorial-to-show-preload-status/240280/1 "2007-10-01T16:43:21Z")

</div>

Hey, guys!

I am working on this tutorial [http://www.kirupa.com/developer/mx/p...transition.htm](http://www.kirupa.com/developer/mx/p...transition.htm)

It teaches us how to make transitions between external swf´s in a really nice way. However, it does not display any preloading data when it loads an external swf, but a blinking “preloading” text. I am trying to adapt it so it will show the percentage loaded in a dynamic textfield.

Here is the original code:

```auto

onClipEvent (enterFrame) {
 if (!loaded && this._url != _root._url) {
  if (this.getBytesLoaded() == this.getBytesTotal()) {
   loaded = true;
   _root.transition.gotoAndPlay("opening");
  }
 }
}

```

And here is what I´ve got (not working):

```auto

onClipEvent (enterFrame) {
 var mclL:Object = new Object();
 mclL.onLoadInit = function() {
  percent.text = Math.round((this.getBytesLoaded()/this.getBytesTotal())*100)+"%";
 };
 this.addListener(mclL);
 if (!loaded && this._url != _root._url) {
  if (this.getBytesLoaded() == this.getBytesTotal()) {
   loaded = true;
   _root.transition.gotoAndPlay("opening");
  }
 }
}

Any help will be really welcome. Thanks in advance, guys!

```
