How can i focus a field in a subform ?

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hi,

In the main form i have a tab control which includes a sub form.
My question is that how can I focus on a field from the main form to the
subform which is in the tab control ?
 
Each form has an ActiveControl. You need to make the subform control on the
main form the active control, and then specify which control in the subform
is the active control there.

Try something like this:

Me.[NameOfYourSubformControl].SetFocus
Me.[NameOfYourSubformControl].Form![NameOfControlInSubform].SetFocus
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top