# Having two different telltargets on one button?

**URL:** <https://forum.kirupa.com/t/having-two-different-telltargets-on-one-button/23238>\
**Category:** Uncategorized\
**Created:** [June 15, 2003, 2:51am UTC](https://forum.kirupa.com/t/having-two-different-telltargets-on-one-button/23238 "2003-06-15T02:51:35Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![chrono](https://avatars.discourse-cdn.com/v4/letter/c/54ee81/32.png) [@chrono](https://forum.kirupa.com/u/chrono)\
**Post date:** [June 15, 2003, 2:51am UTC](https://forum.kirupa.com/t/having-two-different-telltargets-on-one-button/23238/1 "2003-06-15T02:51:35Z")

</div>

Hi everyone.

Before I start, let me say that I tried searching for this, and I didnt come up with any results that helped me.

Ok.

I currently have a button that plays a movie clip when clicked. the code looks like this:

```php

on (release) {
    tellTarget ("lava") {
        gotoAndPlay(2);
    }
}

```

simple enough.

Now, when the user clicks on this same button again (while the movie clip is currently playing) I want the movieclip to switch to a different one.

How might I go about doing this?

---

<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:** [June 15, 2003, 5:55am UTC](https://forum.kirupa.com/t/having-two-different-telltargets-on-one-button/23238/2 "2003-06-15T05:55:34Z")

</div>

welcome, chrono. =)

as stated in the sticky thread [Please read before posting](http://www.kirupaforum.com/forums/showthread.php?s=&threadid=7457), specify your version of flash.

thanks. 😉

---

<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:** [June 15, 2003, 3:04pm UTC](https://forum.kirupa.com/t/having-two-different-telltargets-on-one-button/23238/3 "2003-06-15T15:04:43Z")

</div>

sorry i didnt see the sticky :sigh: I’ll go read it now!

Anyways I have flash mx

---

<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:** [June 15, 2003, 3:49pm UTC](https://forum.kirupa.com/t/having-two-different-telltargets-on-one-button/23238/4 "2003-06-15T15:49:17Z")

</div>

ok… you could try something like this:

```auto
on (release) {
if (lava._currentframe != 1) theOtherMovieClip.gotoAndPlay(2);
else lava.gotoAndPlay(2);
}

```

😉

---

<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:** [June 15, 2003, 4:09pm UTC](https://forum.kirupa.com/t/having-two-different-telltargets-on-one-button/23238/5 "2003-06-15T16:09:10Z")

</div>

Ahh works perfectly now!

Thanks alot for the help! :thumb:

---

<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:** [June 15, 2003, 4:21pm UTC](https://forum.kirupa.com/t/having-two-different-telltargets-on-one-button/23238/6 "2003-06-15T16:21:02Z")

</div>

no problem. =)
