# Tween Event + Parameter listener must be non-null

**URL:** <https://forum.kirupa.com/t/tween-event-parameter-listener-must-be-non-null/293179>\
**Category:** flash\
**Created:** [July 24, 2009, 9:58am UTC](https://forum.kirupa.com/t/tween-event-parameter-listener-must-be-non-null/293179 "2009-07-24T09:58:34Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![romit\_2034](https://avatars.discourse-cdn.com/v4/letter/r/ed655f/32.png) [@romit\_2034](https://forum.kirupa.com/u/romit_2034)\
**Post date:** [July 24, 2009, 9:58am UTC](https://forum.kirupa.com/t/tween-event-parameter-listener-must-be-non-null/293179/1 "2009-07-24T09:58:34Z")

</div>

Hi, I am trying to call one tween event after another one has finished. My code is

```auto

    mv2 = new Tween(png4_mc,"y", Regular.easeInOut, png4_mc.y,100,0.8,true); 
    mv2.addEventListener(TweenEvent.MOTION_FINISH, play1);
    function play1(event:TweenEvent){
            mv = new Tween(png4_mc,"scaleX", Regular.easeInOut, 0.1, 1,0.5,true);
            mv1 = new Tween(png4_mc,"scaleY", Regular.easeInOut, 0.1, 1,0.5,true);         
     }

```

This whole thing is happening inside a switch statement. I have also declared mv, mv1 and mv2 outside the switch.

I get the following error

“Parameter listener must be non-null.”

And the event listener never fires the other function…

What am I doing wrong?
