# \[Flash8\] Need help using Tween class

**URL:** https://forum.kirupa.com/t/flash8-need-help-using-tween-class/182857
**Category:** flash
**Created:** [March 22, 2006, 12:32am UTC](https://forum.kirupa.com/t/flash8-need-help-using-tween-class/182857 "2006-03-22T00:32:25Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![srucker](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/srucker/32/2280_2.png) [@srucker](https://forum.kirupa.com/u/srucker)
#### Post date: [March 22, 2006, 12:32am UTC](https://forum.kirupa.com/t/flash8-need-help-using-tween-class/182857/1 "2006-03-22T00:32:25Z")

</div>

I am trying to use the Tween class to first rotate an object and then after the rotation is finished, use a new tween to move the object off the screen. Here is my code:

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

var barT:Tween = new Tween( this.loader\_bar, “\_rotation”, Elastic.easeOut, 0, 90, 1.5, true );

barT.onMotionFinished = function() {  
trace( “onMotionFinished” );  
barT = new Tween( this.loader\_bar, “\_y”, Regular.easeOut, 500, 800, 1.5, true );  
}

The trace runs, just as expected, right after the first Tween completes. But the second Tween doesn’t work. What am I doing wrong?

---

<div class="post-metadata">

### Author: ![TheCanadian](https://avatars.discourse-cdn.com/v4/letter/t/67e7ee/32.png) [@TheCanadian](https://forum.kirupa.com/u/TheCanadian)
#### Post date: [March 22, 2006, 2:12am UTC](https://forum.kirupa.com/t/flash8-need-help-using-tween-class/182857/2 "2006-03-22T02:12:11Z")

</div>

In the _onMotionFinished_ function, _this_ refers to _barT_ 😉
