# Please please help

**URL:** <https://forum.kirupa.com/t/please-please-help/185493>\
**Category:** Uncategorized\
**Created:** [April 13, 2006, 6:07pm UTC](https://forum.kirupa.com/t/please-please-help/185493 "2006-04-13T18:07:03Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![joe\_poth](https://avatars.discourse-cdn.com/v4/letter/j/e47c2d/32.png) [@joe\_poth](https://forum.kirupa.com/u/joe_poth)\
**Post date:** [April 13, 2006, 6:07pm UTC](https://forum.kirupa.com/t/please-please-help/185493/1 "2006-04-13T18:07:03Z")

</div>

```auto
on (release) = function()
{
    _root.ContentMC.gotoAndStop(2)//frame i want to hold for one second
    setInterval(linkInt,"link",1000) //clear interval command to be in frame last played
    function(link){_root.ContentMC.gotoAndStop(3)};//final frame player stays here
};

```

that is a code i have written for a button on a website. but i cannot get it to work. can anyone please help?

what i need it to do is to go to the first frame, stop, hold for one second, then go to the second frame. the clear interval command will be in the last frame played. and i cannot just play two frames beside eachother, as they will not always be corrisponding with one another, they will be mixed combinations. that is why it is so important that the code is in the button.

please please help me… :crying:

---

<div class="post-metadata">

**Author:** ![flextnet](https://avatars.discourse-cdn.com/v4/letter/f/7ba0ec/32.png) [@flextnet](https://forum.kirupa.com/u/flextnet)\
**Post date:** [April 13, 2006, 9:09pm UTC](https://forum.kirupa.com/t/please-please-help/185493/2 "2006-04-13T21:09:01Z")

</div>

setInterval(linkInt,“link”,1000)

should be changed to

\_root.linkInt = setInterval(link,1000);

then in your final frame

clearInterval(\_root.linkInt);

---

<div class="post-metadata">

**Author:** ![joe\_poth](https://avatars.discourse-cdn.com/v4/letter/j/e47c2d/32.png) [@joe\_poth](https://forum.kirupa.com/u/joe_poth)\
**Post date:** [April 14, 2006, 4:35pm UTC](https://forum.kirupa.com/t/please-please-help/185493/3 "2006-04-14T16:35:36Z")

</div>

thanx for your help flextnet, but there is still something not working in it, showing the following errors…

**Error** Symbol=Naivgation, layer=buttons, frame=2:Line 1: ‘{’ expected  
on (release) = function()

**Error** Symbol=Naivgation, layer=buttons, frame=2:Line 2: Statement must appear within on handler  
{

with this modified code…

```auto
on (release) = function()
{
    _root.ContentMC.gotoAndStop(2)
    _root.linkInt = setInterval(link,1000);
    function(link){_root.ContentMC.gotoAndStop(3)};
}

```

can anyone see the problem with it? starting to wreck my nerves… :crying:

---

<div class="post-metadata">

**Author:** ![flextnet](https://avatars.discourse-cdn.com/v4/letter/f/7ba0ec/32.png) [@flextnet](https://forum.kirupa.com/u/flextnet)\
**Post date:** [April 14, 2006, 6:44pm UTC](https://forum.kirupa.com/t/please-please-help/185493/4 "2006-04-14T18:44:50Z")

</div>

You need to put that code on the button instance, and it looks like you have it on the frame.

---

<div class="post-metadata">

**Author:** ![joe\_poth](https://avatars.discourse-cdn.com/v4/letter/j/e47c2d/32.png) [@joe\_poth](https://forum.kirupa.com/u/joe_poth)\
**Post date:** [April 14, 2006, 10:50pm UTC](https://forum.kirupa.com/t/please-please-help/185493/5 "2006-04-14T22:50:21Z")

</div>

> [@flextnet](#):
>
> You need to put that code on the button instance, and it looks like you have it on the frame.

no mate, definatly on the button. dont understand it. im not that good at as, well nearly useless at it, but i cant see the problem with it, and it just wont work. leaves the button so that it does nothing. anyone got an idea what’s wrong with it???

---

<div class="post-metadata">

**Author:** ![flextnet](https://avatars.discourse-cdn.com/v4/letter/f/7ba0ec/32.png) [@flextnet](https://forum.kirupa.com/u/flextnet)\
**Post date:** [April 14, 2006, 11:14pm UTC](https://forum.kirupa.com/t/please-please-help/185493/6 "2006-04-14T23:14:36Z")

</div>

Are you still getting the complie errors? Can you post the fla?

---

<div class="post-metadata">

**Author:** ![joe\_poth](https://avatars.discourse-cdn.com/v4/letter/j/e47c2d/32.png) [@joe\_poth](https://forum.kirupa.com/u/joe_poth)\
**Post date:** [April 15, 2006, 10:29am UTC](https://forum.kirupa.com/t/please-please-help/185493/7 "2006-04-15T10:29:26Z")

</div>

yes still getting the error messages, any help with this would be greatly, greatly appreciated.

had to zip the file before uploading it because it’s over the size allowance.
