# Btn within mc problem

**URL:** <https://forum.kirupa.com/t/btn-within-mc-problem/262379>\
**Category:** Uncategorized\
**Created:** [June 5, 2008, 2:54pm UTC](https://forum.kirupa.com/t/btn-within-mc-problem/262379 "2008-06-05T14:54:36Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![magicmule](https://avatars.discourse-cdn.com/v4/letter/m/e9bcb4/32.png) [@magicmule](https://forum.kirupa.com/u/magicmule)\
**Post date:** [June 5, 2008, 2:54pm UTC](https://forum.kirupa.com/t/btn-within-mc-problem/262379/1 "2008-06-05T14:54:36Z")

</div>

On my timeline I have several navigation buttons (mcs) that i would like to be deacivated on frame 1 only. The mcs have a button within them. There are 10 mcs with buttons inside them with instance names like this:

mc\_btn1  
btn1

mc\_btn2  
btn2

etc etc.

my code in the first frame of the timeline is set to deactivate the buttons and looks liek this:

\_root.btn1.enabled = false;  
\_root.btn2.enabled = false;  
\_root.btn3.enabled = false;  
\_root.btn4.enabled = false;  
\_root.btn5.enabled = false;  
\_root.btn6.enabled = false;  
\_root.btn7.enabled = false;  
\_root.btn8.enabled = false;  
\_root.btn9.enabled = false;  
\_root.btn10.enabled = false;

I have tried several variations, with and without the \_root adding the mc\_btn1 reference etc, but still does not deactivate the buttons. i can still click them in frame 1. any ideas?

thanks

---

<div class="post-metadata">

**Author:** ![matthewjumps](https://avatars.discourse-cdn.com/v4/letter/m/49beb7/32.png) [@matthewjumps](https://forum.kirupa.com/u/matthewjumps)\
**Post date:** [June 9, 2008, 3:34am UTC](https://forum.kirupa.com/t/btn-within-mc-problem/262379/2 "2008-06-09T03:34:31Z")

</div>

\_root.mc\_btn1.btn1.enabled = false should work if you have the instance names correct. Double check your instance names, and then post your .fla if you cant get it to work so we can fix it for you 😉

---

<div class="post-metadata">

**Author:** ![magicmule](https://avatars.discourse-cdn.com/v4/letter/m/e9bcb4/32.png) [@magicmule](https://forum.kirupa.com/u/magicmule)\
**Post date:** [June 10, 2008, 1:34pm UTC](https://forum.kirupa.com/t/btn-within-mc-problem/262379/3 "2008-06-10T13:34:06Z")

</div>

i got it working. thanks

---

<div class="post-metadata">

**Author:** ![excogitator](https://avatars.discourse-cdn.com/v4/letter/e/d26b3c/32.png) [@excogitator](https://forum.kirupa.com/u/excogitator)\
**Post date:** [June 11, 2008, 7:14am UTC](https://forum.kirupa.com/t/btn-within-mc-problem/262379/4 "2008-06-11T07:14:22Z")

</div>

Just in case this hack goes for everyone. For all those having lots of buttons on stage and there are no movieclip or mousedown events being called. Just put an invisible button on stage on top of them all, name it invisbtn and set code as  
invisbtn.useHandCursor=false;

Voila!!  
To resume all button functionalities just remove this button dynamically or set it off stage.  
Hope everyone finds this useful and skip enabling and disabling a whole lot of buttons.
