View Full Version : Disable Tab Button

03-18-2007, 01:29 AM

How do I go about disabling the tab button in Flash? If you've noticed, when you press the tab button on your keyboard while viewing a flash movie, a yellow box appears around all buttons and MC's with actions attached (even plaing the onRollOver/Out states on occassion.

I have some MCs on a page with a form. I'm sure some users will be using the tab button as I also do when filling out forms. I find these yellow boxes to be quite unsigthly!

Does anyone know of a way to disable this? I'm pretty sure it's possible.

For example, if you look at those point-and-click games...the really well made ones will have this feature diabled so you can't figure out what is clickable (and thus might produce an advtangeous result) simply by pressing tab.


03-18-2007, 02:19 AM
I don't know the code off the top of my head, but from my experience, you can control events with actionscript based on keys pressed. All you need to do is figure out which command is needed to do something for the tab button, then do something like "return false" which is javascript (closely related to actionscript), but basically disables the default event. Or, perhaps, just "do" something else, such as add one to an extraneous variable, which might override the default.

03-18-2007, 02:11 PM
For the MCs:

movieClip.tabEnabled = false;

If you have parent/child set up and all your MC's are in one MC then use:

movieClip.tabChildren = false;

And yes, for each one... I haven't come across a global version yet, but I am trying... slowly and with less care... LOL