Using a simple function to display a button but then

here’s something a little frustrating!

simply speaking,

create a button, create a movie clip with two frames.

place a button instance in frame 2.

place a mc instance on the stage.

create another instance of the button to change the movie clip instance to frame two.

the button in the movie clip is pressed and executes a function.

here’s the code

// create the button to show the button!
_root.button_instance_2.onPress = function() {
	buttonClick1();
};
// set the movie clip instance frame
function buttonClick1() {
	_root.button_container_instance.gotoAndStop(2);
}
// create the function, target the button instance within the movie clip instance.
_root.button_container_instance.button_instance_1.onPress = function() {
	buttonClick2();
};
function buttonClick2() {
	trace("button hit");
}

this doesn’t work!

if, however, i use the same code on a movie clip that has only one frame it will work fine. do i need to tell the function to target the button instance any more specifically than that?

:puzzle:

thanks in advance guys