The DoCmd GoToControl method moves the cursor (sets focus to) a field or control on a form in VBA. The control name is the only option available for the Goto Control statement:
Note that you may employ the GoTo Control method to move to a subform, which is a type of control. You can then use the GoToRecord method to move to a specific record in the subform. You can also move to a control on a subform by using the GoToControl action to move first to the subform and secondly to a control within subform.
More GotoControl Examples:
MS Access 2003
Copyright 2000-2017 Blue Claw Database Design