Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

ProcessTabKey from Custom User Control

Status
Not open for further replies.

drewson

MIS
Jun 3, 2003
50
US
Hi,

I've created a custom user control in VB.NET called kTextBox for a data entry application that includes a textbox and a picturebox in the control. The picturebox is just used to show the user whether the textbox has been validated. Every time the user hits ENTER while in the textbox, I want the cursor to move from one user control to the next on the form.

I've used the MyBase.ProcessTabKey(True) successfully only when there are multiple text boxes on one form. How can I code the ENTER key to move from the textbox control in my kTextBox control to the textbox in the next kTextBox control? The MyBase.ProcessTabKey(True) seems to only work within the kTextBox custom control and does not move the cursor out of the kTextbox custom control.

Thanks!
Drew
 
Got it.

MyBase.ProcessDialogKey(Keys.Tab)

Won't work for shift-tab, but that's ok.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top