Tabbing through Controls - 2nd post

G

Guest

Tabbing from the first control on a form always sends me to IE's Address Bar
instead of the next control, no matter how I set the TabIndex property for
the controls. Why is this happening?

For example, I have a simple login screen with 2 textboxes (Login ID and
Password) and 2
buttons (Login and Cancel). I've set the TabIndex Property of each control,
starting at 0.

When I enter a login id and then press Tab, the focus goes to IE's Address
Bar instead of the next control! How do I allow the user to reliably cycle
through the controls on a web page?
 
K

Ken Cox [Microsoft MVP]

Don't use zero. Start at 1 and see if that works?

<P>
<asp:TextBox id="TextBox1" tabIndex="1"
runat="server"></asp:TextBox></P>
<P>
<asp:TextBox id="TextBox2" tabIndex="2"
runat="server"></asp:TextBox></P>
<P>
<asp:Button id="Button1" tabIndex="3" runat="server"
Text="Button"></asp:Button></P>
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,744
Messages
2,569,484
Members
44,903
Latest member
orderPeak8CBDGummies

Latest Threads

Top