T
tina
in the last control in the tab order of your subform, add
code to the OnExit event, as
Me.Parent.ControlName.SetFocus
change "ControlName" to the name of the control you want
to go to on the main form. (i think i got the syntax right
for the Parent reference. if it won't work, you can use
Forms!MainFormName! instead of Me.Parent.)
fyi, this can be a pain if your user tries to click on
another control on the main form or the subform, while the
control that runs the code has the focus - regardless of
where the user clicks, the focus will move to the control
specified in the code.
hth
code to the OnExit event, as
Me.Parent.ControlName.SetFocus
change "ControlName" to the name of the control you want
to go to on the main form. (i think i got the syntax right
for the Parent reference. if it won't work, you can use
Forms!MainFormName! instead of Me.Parent.)
fyi, this can be a pain if your user tries to click on
another control on the main form or the subform, while the
control that runs the code has the focus - regardless of
where the user clicks, the focus will move to the control
specified in the code.
hth