Question : How to make a field in the header of a form the first tab stop?

How to make a field in the header of a form the first tab stop?  I field EmployerCode to be the first tab stop when opening my form.  It is selected when I click header, but it continually goes to the first tab stop in my form detail section.

Thank you!!

Answer : How to make a field in the header of a form the first tab stop?

You need to add some code to the forms OnOpen and OnCurrent events.

In the forms declartion section, add a global variable:

Dim bolJustOpened as Booleen

In the OnOpen

bolJustOpened = True

and in the OnCurrent:

 If bolJustOpened = True then
    Me..setfocus
    bolJustOpened = False
 End If

JimD.

Random Solutions  
 
programming4us programming4us