AS2: **movieclip button**

Hi

I have created a movieclip that i am using as a button. The movieclip is inside another movieclip and i use an attachMovie script to add it.

The actionscript that for this is in the timeline:

//attaches movieclip
container.attachMovie(“next”, “nextbutton”, 1);

//what the movieclip does as a button
container.nextbutton.onRelease = function(){
container.attachMovie(“input”, “input”, 2, {_y:0});
container.nextbutton.removeMovieClip();
container.attachMovie(“next”, “nextbutton”, 3, {_y:45});
}

The problem is when i use removeMovieClip and reattach the same movieclip it loses it’s button like properties.

I need to know how i can put the actionscript inside the movieclip itself without refrence to it from the timeline and i don’t know how to do that.

Any help is really appreciated.

Thanks, Tom