setting focus in subform

  • Thread starter Thread starter Jean-Paul
  • Start date Start date
J

Jean-Paul

Hi,

I am puzzled with the syntax to set focus to a field in a subform.
I wrote:

Forms![verslagen]![Sub_Bedrijsgegevens].Form!Adres.SetFocus

Where [verslagen] is the main form name and
[Sub_Bedrijsgegevens] the name of the subform

Adres is the name of the field....

What am I doing wrong?
Thanks
 
You need to set focus on the subform control first:

Forms![verslagen]![Sub_Bedrijsgegevens].SetFocus
Forms![verslagen]![Sub_Bedrijsgegevens].Form!Adres.SetFocus
 
Back
Top