# Transition class

**URL:** <https://forum.kirupa.com/t/transition-class/242067>\
**Category:** Uncategorized\
**Created:** [October 22, 2007, 3:14am UTC](https://forum.kirupa.com/t/transition-class/242067 "2007-10-22T03:14:44Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![punstc](https://avatars.discourse-cdn.com/v4/letter/p/87869e/32.png) [@punstc](https://forum.kirupa.com/u/punstc)\
**Post date:** [October 22, 2007, 3:14am UTC](https://forum.kirupa.com/t/transition-class/242067/1 "2007-10-22T03:14:44Z")

</div>

i’m trying to use the transition class to create a fade out and fade in for loading in external movies. I found a tutorial on it searching through the forums on the topic. I’m having a troubles though when i click on my buttons nothing occurs. I’ve checked my script with the source script and its identical as far as i can see except for the slight changes i made since my buttons are inside of another movie clip and perform actions inside. Can anyone have a look and see if i have any errors or just going about all wrong.

```auto

import mx.transitions.Tween;
import mx.transitions.easing.*;

//Transitions & Navigation

var mcl:MovieClipLoader = new MovieClipLoader();

var mclL:Object = new Object();

mcl.addListener(mclL);

mcl.loadClip("news.swf",holder_mc);

mclL.onLoadStart = function(){
   preloader_mc.progress_mc._width = 0;
   preloader_mc._visible = true;
   theText._visible = true;
   
   }
   
   mclL.onLoadProgress = function(target,loaded,total){
      theText.text = "Loading" +Math.round((loaded/total)*100) + "%";
      preloader_mc.progress_mc._width = preloader_mc.base_mc._width * (loaded/total);
      
      
      }
   
   mclL.onLoadInit = function(){
  preloader_mc._visible = false;
  theText._visible = false;
  var myTween1:Tween = new Tween(holder_mc, "_alpha",Back.easeOut,0,100,1,true);
  initButtons();

}
     
     

function initButtons():Void {  
nav.b_news.onRelease = function(){
   nav.gotoAndStop("Closed");
    var myTween2:Tween = new Tween(holder_mc, "_alpha",Back.easeOut,100,0,1,true);
    myTween2.onMotionFinished = function(){
    mcl.unloadClip(holder_mc);
    mcl.loadClip("news.swf",holder_mc);
      
      }
    
    }
      
nav.b_web.onRelease = function(){
   nav.gotoAndStop("Closed");
    var myTween2:Tween = new Tween(holder_mc, "_alpha",Back.easeOut,100,0,1,true);
    myTween2.onMotionFinished = function(){
    mcl.unloadClip(holder_mc);
    mcl.loadClip("web.swf",holder_mc);
      
      }
    
    }
}

         
stop();

```

thanks in advance
