# Button disable?

**URL:** <https://forum.kirupa.com/t/button-disable/29491>\
**Category:** Uncategorized\
**Created:** [August 27, 2003, 2:14pm UTC](https://forum.kirupa.com/t/button-disable/29491 "2003-08-27T14:14:22Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![Ashleek007](https://avatars.discourse-cdn.com/v4/letter/a/e5b9ba/32.png) [@Ashleek007](https://forum.kirupa.com/u/Ashleek007)\
**Post date:** [August 27, 2003, 2:14pm UTC](https://forum.kirupa.com/t/button-disable/29491/1 "2003-08-27T14:14:22Z")

</div>

when I load a movie over the top of another movie the button underneath is still active

does anyone know if I can disable this button so it doesnt interfere with the movie on top?

cheers:)

---

<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 27, 2003, 3:45pm UTC](https://forum.kirupa.com/t/button-disable/29491/2 "2003-08-27T15:45:45Z")

</div>

```auto

this.enabled = false;

```

---

<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 27, 2003, 3:48pm UTC](https://forum.kirupa.com/t/button-disable/29491/3 "2003-08-27T15:48:14Z")

</div>

“this” on buttons targets it’s parent. Something I learned from kax 😉 So it might be possible that you have to use [AS]this.instancenameofthisbutton.enabled = false;[/AS]

---

<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 27, 2003, 3:52pm UTC](https://forum.kirupa.com/t/button-disable/29491/4 "2003-08-27T15:52:00Z")

</div>

Digitalosophy’s code should work if it’s within an onRelease.

```auto
mybutton.onRelease = function () {
trace( this );
}
// traces _level0.mybutton

```

🙂

---

<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 27, 2003, 4:29pm UTC](https://forum.kirupa.com/t/button-disable/29491/5 "2003-08-27T16:29:51Z")

</div>

[http://www.kirupaforum.com/forums/showthread.php?s=&threadid=32719](http://www.kirupaforum.com/forums/showthread.php?s=&threadid=32719)

---

<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 27, 2003, 4:30pm UTC](https://forum.kirupa.com/t/button-disable/29491/6 "2003-08-27T16:30:03Z")

</div>

Correct, if you put ahmed’s on root, it’ll target the button. If you put it on the button itself, it will target it’s parent. That makes no sense actually 😛

---

<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 27, 2003, 4:53pm UTC](https://forum.kirupa.com/t/button-disable/29491/7 "2003-08-27T16:53:39Z")

</div>

Can’t you just put on the timeline where you want the button disabled:

```auto

_root.myButton.enabled = false;

```

??  
Or is that sloppy? :-\

---

<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 31, 2003, 5:28pm UTC](https://forum.kirupa.com/t/button-disable/29491/8 "2003-08-31T17:28:57Z")

</div>

OK i have my buttons turing off but they wont’ turn back on

:edit: never mind reversed the variables.:edit:
