Heatshiver
Registered User.
- Local time
- Tomorrow, 03:48
- Joined
- Dec 23, 2011
- Messages
- 263
I have two subforms on a main form. I was wondering if there was a way to capture the tab key so that when they reach the last field on the first subform it will tab them into the first field of the second subform?
What I have so far is to turn on the KeyPreview in the first subform's load function. I then use the KeyDown event on the last field of the first subform. I then have the following code:
The code runs without an error, but instead continues on to the next field in that subform... Any help is much appreciated!
What I have so far is to turn on the KeyPreview in the first subform's load function. I then use the KeyDown event on the last field of the first subform. I then have the following code:
Code:
Select Case KeyCode
Case vbKeyTab
Forms![frmMudCop].[fsubSolidCtrlSum2].Form.[ScreenSize(CD12)].SetFocus
Case Else
End Select