gotoAndPlay
I am trying to use the gotoAndPlay() function but unfortunately it will not work for me. The only thing I can think of why this is happenning is that I am using multiple swf’s being loaded using the “loadClip” into empty MC. There is a root.swf… calls 2nd.swf… calls 3rd.swf… which calls 4th.swf.
Inside the 4th.swf, I have a Movie Clip on frame one. On frame 2, there is a Label called “quiz”. Inside the Movie Clip on Frame One, I have the code on the button:
on(release) {
trace(“button not working”); // this is for testing purposes which does output
_root.gotoAndPlay(“quiz”);
}
I have also tried the code on the actions layer:
takeTestBtn.onRelease = function() {
trace(“button not working”); // this is for testing purposes which does output
_root.gotoAndPlay(“quiz”);
}
Neither of these work. I created a new FLA and did exactly the same thing in there and it worked fine so I am thinking that it has to do something with the multiple nested swf’s. Any idea how to get this to work? Should I try calling the level the swf is on, and if so, how do I know what level it is on?