Question with buttons

i am making a page that is only 2 frames long and with alot of movieclips…my problem is, how do I make the buttons go to a new scene when released in mx…i am sure this is a stupid question, but i cant seem to do it for the life of me…


just make it go:

on (release){
gotoAndPlay(“Scene 2”, 2);

If it’s scene 2, don’t use frame numbers. If scene1 has 2 frames, and scene2 has 2 frames, and you call to (scene2,2) you’ll still end up in scene1. The scenes are all flattened so to speak when you publish. So, it’s better to use frame labels.

create a blank layer, Where ever you would like to goto with an a/s statement, place a blank keyframe. Open up the “Frame” panel, and enter a distinguishing frame name.

the in the goto statement you can use something like


I had a similar situation a while back, and I did use the NextScene() command, and it works. However, it did not work at first because when you use NextScene(), it DOES go to the next scene, but it stops! So, I had to tell frame1 in Scene 2 to play frame 2.

All that to say, that although NextScene() works, I still like Upuaut’s method better.

this is my problem

I add actions to each button

like for button 2
i tell it to go to scene 2 and it does,

but button 3, i tell it to go to scene 3 and it still goes to scene 2
this also happens with button4 and so on…
will the frame labels work for other scens as well?
and how do i add a frame label in mx…



Ok, I added labels to the frames as well, it just only goes to scene 2, even when i press the buttont to take me to scene 3…what is going on

please post the action script from your buttons so we can take a look at what you’ve done so far. If there are a lot of buttons, three or four should do. Please indicate which of the buttons are working and which are not.

ok this is the actionscripts for each button with the frame labels on them…i am not sure which frame I should label, so i labeled the first frame of the first layer of each scene

button 1= main page
on (release) {
&nbsp &nbsp &nbsp &nbsp gotoAndPlay(“1”, “scene1frame1”);

button 2 = updates page

on (release) {
&nbsp &nbsp &nbsp &nbsp gotoAndPlay(“2”, “scene2fram1”);

button 3 = 3rd scene

on (release) {
&nbsp &nbsp &nbsp &nbsp gotoAndPlay(“scene3frame1”);

i have more buttons, but u get the point…

if I press the third button to go to the third scene, it goes to the second scene. Even when I press the frst button, which it should just reload the same page, it still jumps to the second scene. If you need any more info i can post more…



ahh… I see the problem.

The syntax for the goto statement is this


as for where the frame labels go. There is no set rule, but I personaly create a new blank layer, change the name of the layer to “frameLabels” just so I can keep track of it, and then I place my frame labels where I need them in that layer.

If you want a frame label out in the middle of the timeline somewhere, just create a blank keyframe where you want the label to be, then select that frame and type in the frame label in the “frame” panel.