Tab Indexes

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

vb.net 2005

im trying to move focus from one control to another using the tab index.
For varios reasons i don not want to use send keys or control.focus.
 
Peter Newman said:
im trying to move focus from one control to another using the tab index.
For varios reasons i don not want to use send keys or control.focus.

Well, calling the control's 'Focus' method is the preferred method. What
are the reasons you do not want to use this method?
 
what i want to do is when the user hits the return/enter key they tab to the
next control. However i want to put this in a class so that all forms can
inherit it
 
Peter said:
what i want to do is when the user hits the return/enter key they tab to the
next control. However i want to put this in a class so that all forms can
inherit it

Probably not best done in the Form, but in the Controls you place onto it.

Call [Control].SelectNextControl() in your override for OnKeyDown (or
OnKeyUp; I can never remember which until my program goes pop!)

Regards,
Phill W.
 

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

Similar Threads

setting default focus 7
Vb.net 2008 - Reference control collection by name? 3
Tab Control 6
Newbie 7
Excel Move or Copy Stopped Working? 0
VB[2008] - Help Provider - no tabs being displayed in html help 1
Windows 10 Itunes/TabKey 0
Setting focus 2

Back
Top