Solved

Focus on tab or shift tab

Posted on 2008-10-19
4
1,027 Views
Last Modified: 2013-11-11
Lets say you have two text boxes with the name txtUsername and txtPassword.  Using ActionScript 3 how do you change focus to password when tab is pressed or even shift tab to go up to username.  

I am looking at the FocusManager documentation but i can't get it to work.  Any examples
0
Comment
Question by:stargateatlantis
  • 2
  • 2
4 Comments
 
LVL 34

Accepted Solution

by:
Aneesh Chopra earned 500 total points
ID: 22752688
you Just need to add following code:


txtUsername.tabIndex = 0;
txtPassword.tabIndex =1;


IMPORTANT:
To test the tab indexing in Flash authoring environment, you must "Disable Keyboard Shortcuts", see attached image for more details
disableKeyboardShortCuts.jpg
0
 

Author Comment

by:stargateatlantis
ID: 22753020
it doesn't work.  
0
 
LVL 34

Assisted Solution

by:Aneesh Chopra
Aneesh Chopra earned 500 total points
ID: 22753137
It does work perfectly,
I request to attach your sample file for review so that I can let you know the cause of the issue and as well as solution.
0
 

Author Comment

by:stargateatlantis
ID: 22788622
The reason its not working and i found out why but it would be good to disable.    I am loading a Animation file that was created in Flash 8.  For some reason the tabindex is getting lost from this.  Is there anyway to disable the tabindex on the loaded Animation.

var loadit = new Loader();
loadit.load(new URLRequest("loginnew.swf"));
mcCon.addChild(loadit);

Open in new window

0

Featured Post

Live: Real-Time Solutions, Start Here

Receive instant 1:1 support from technology experts, using our real-time conversation and whiteboard interface. Your first 5 minutes are always free.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I have been doing hardcore actionscripting for some time; and needless to say I have faced a lot of problems in just understanding others' code rather than understanding what the code executes. A programmer's life can become hell when there are a lo…
While working over numerous projects I often had the requirement for doing a screen capture in AS3.0. Unfortunately I found no "ready made" solutions in google search that suited my requirements. But I did come across some great resources which help…
In this tutorial viewers will learn how to create a basic shape tween animation in Flash including shape hints for smooth animation Open a new document in Flash: Draw a shape: Select another frame (how long you want the tween to be): Right click and…
The goal of the tutorial is to teach the user how to how to load their YouTube profile onto Flash Media Live Encoder.

776 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question