Taborder between asp:textboxes

  • Thread starter Thread starter Jane Sharpe
  • Start date Start date
J

Jane Sharpe

Hi,

I have a form which contains a number of textboxes, they are defined like
this :

<asp:TextBox id="txtEmail" MaxLength="128" runat="server"
class="DataTextBoxMedium" onkeydown="TrapKBD()" />

At the moment as the user enters information, and presses the tab key, they
are taken down the textboxes in the order they appear on the form, 1,2,3,4
etc.

I'd like to change this order (not based on any input) but just make sure
the tab key takes a different route, say 1,3,2,4 .....

Can I do that? and how ?

Jane
 
Are you wanting to have the tab order change each time
the app loads or just have the tab order 1, 3, 2, 4. If
its the latter, just change the tab order or tab index of
each control in the properties window starting with
0....then continue with 2, 1, 3. Hope this helps!!
 
It does a bi thanks....... but I dont have Visual Studio.... so can you tell
me the syntax it generates int the unerlying code ??

Jane..
 
What software package are you using? Are you just using
the .NET SDK? Well if you were to use visual studio and
then drop a text box onto your form and then change its
tab (or index) order, the underlying code that is
generated by the designer is this this.button1.TabIndex =
0....or what ever number you specify. This code snippet
is what it would look like if C# was the primary
language. If C++ is used then
this->button1->TabIndex = 0...ect. Let me know if this
helps!!
 
Back
Top