I'm using CS4 Professional with ActionScript 2.0.

I'm working with a movie that contains 23 Tab keypress interactions, each of which uses this code (with each one navigating to a different frame number):

Actionscript Code:
var kl = new Object();
kl.onKeyDown = function(){
    if(Key.isDown(Key.TAB)){
        gotoAndPlay(20);
    }
};
Key.addListener(kl);

When I publish and play the movie, everything is fine until I hit the tenth interaction, at which point it plays more and more slowly. After about the thirteenth interaction a message displays that says,
"A script in this movie is causing Adobe Flash Player to run slowly. If it continue to run, your computer may become unresponsive. Do you want to abort the script?"

If I abort the script, the movie starts playing on its own without any user interaction, which is not what I want to happen.

Any ideas about how to get around this problem?

I've tried assigning different names to each variable (kl2, kl3, etc.) but that didn't help. I've also tried setting the value of the variable to null by adding kl="" to the end of the ActionScript. No luck there either.

Any help would be appreciated.

Thanks!