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 SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Changing focus with button press

Status
Not open for further replies.

osp001

Technical User
Nov 19, 2003
79
0
0
US
I should know how to do this, but I'm lost.

I'm trying to get the focus to shift to a certain field after selecting from a "yes/no" data type. Specifically, I would like the cursor to switch to a given field after selecting "yes" or "no"- the same field, regardless of which selection is made.

Sorry for the n00b question- I've been trying to figure this out without success for a while now, and need some help. Thanks!
 
In the checkbox's AfterUpdate event:
Code:
Me.[blue][b]MyControl[/b][/blue].SetFocus
...where [blue]MyControl[/blue] is the name of the field on your form which you wish to have the focus.

HTH,

Ken S.
 
. . . or:
Code:
[blue]   DoCmd.GoToControl "[purple][b]TextboxName[/b][/purple]"[/blue]

Calvin.gif
See Ya! . . . . . .
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top