<(E-Mail Removed)> wrote in message
news:(E-Mail Removed)
> How can be tell the form to display the first record that is
> in a combo box when the form opens?
>
> Software: Access 2002
I'm not sure at what point the combo box's list is populated, compared
to the loading of the form. You could try something like this air code:
'----- start of untested air code -----
Private Sub Form_Load()
With Me!cboMyCombo
If .ListCount > 0 Then
Me.Recordset.FindFirst "IDField=" & .ItemData(0)
End If
End With
End Sub
'----- end of untested air code -----
That assumes that the ID field in the form's recordsource is numeric.
If it's text, we'd need to add quotes to the FindFirst criterion.
--
Dirk Goldgar, MS Access MVP
www.datagnostics.com
(please reply to the newsgroup)