# Making buttons work

**URL:** https://forum.kirupa.com/t/making-buttons-work/61323
**Category:** flash
**Created:** [August 17, 2004, 7:43pm UTC](https://forum.kirupa.com/t/making-buttons-work/61323 "2004-08-17T19:43:53Z")
**Posts on this page:** 8
**Page:** 1

<div class="post-metadata">

### Author: ![flashstupid](https://avatars.discourse-cdn.com/v4/letter/f/35a633/32.png) [@flashstupid](https://forum.kirupa.com/u/flashstupid)
#### Post date: [August 17, 2004, 7:43pm UTC](https://forum.kirupa.com/t/making-buttons-work/61323/1 "2004-08-17T19:43:53Z")

</div>

Ok, what I’ve done is imported graphics into my movie. I’m using those as backgrounds, similar to powerpoint. I want to make buttons that are necessary to move onto the next frame. But when I put in

on(release)  
{  
gotoAndPlay(frame#)  
}

it just skips over it and i can’t click on the button. I don’t have various layers set up for this, maybe that’s what I need to do?

---

<div class="post-metadata">

### Author: ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)
#### Post date: [August 17, 2004, 7:47pm UTC](https://forum.kirupa.com/t/making-buttons-work/61323/2 "2004-08-17T19:47:55Z")

</div>

Welcome to the forums! 🙂

You don’t need layers necessarily (though they are nice for organizing). Sounds like you are missing a stop action. If you have multiple frames but you want to stick on one until someone presses a button then you need to put stop(); on the frame you want to stick on. Then when your button is pressed you can either use the following:

```auto

on(release){
gotoAndStop(frame#)}

```

or put a stop(); on the frame you want to go to and stop at and use gotoAndPlay(frame#) (or gotoAndStop - works just as well I think).

:hr:

---

<div class="post-metadata">

### Author: ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)
#### Post date: [August 17, 2004, 7:57pm UTC](https://forum.kirupa.com/t/making-buttons-work/61323/3 "2004-08-17T19:57:28Z")

</div>

Ok, I tried putting in  
on(release){  
gotoandStop(frame#)  
}

Nothing worked. When I do control\>test movie, it just skips it right over and nothing happens.

Should I be worried about the properties and parameters?

---

<div class="post-metadata">

### Author: ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)
#### Post date: [August 17, 2004, 8:00pm UTC](https://forum.kirupa.com/t/making-buttons-work/61323/4 "2004-08-17T20:00:10Z")

</div>

If I do the other way:

on(release){  
gotoandPlay(frame#)}

and then put a stop() in my destination frame, it does stop in that frame but will not stop to ask me for a click in the other frame. AAAHHHH!

---

<div class="post-metadata">

### Author: ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)
#### Post date: [August 17, 2004, 8:28pm UTC](https://forum.kirupa.com/t/making-buttons-work/61323/5 "2004-08-17T20:28:59Z")

</div>

Like I said, you need to put a stop(); on the frame you want to stick on. So whatever frame your button is on put a stop there.

:hr:

---

<div class="post-metadata">

### Author: ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)
#### Post date: [August 17, 2004, 8:34pm UTC](https://forum.kirupa.com/t/making-buttons-work/61323/6 "2004-08-17T20:34:13Z")

</div>

Here, I mocked up an example for you.

---

<div class="post-metadata">

### Author: ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)
#### Post date: [August 17, 2004, 8:45pm UTC](https://forum.kirupa.com/t/making-buttons-work/61323/7 "2004-08-17T20:45:45Z")

</div>

Thanks, I just had the stop in the wrong place. I’ve got it working like I had wanted. Thanks so much for the help and the example.

---

<div class="post-metadata">

### Author: ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)
#### Post date: [August 17, 2004, 8:50pm UTC](https://forum.kirupa.com/t/making-buttons-work/61323/8 "2004-08-17T20:50:16Z")

</div>

No problem, glad you got it working! :thumb:
