1stTimeOut
Technical User
My form pulls from a table containing two records
[MDN NPA-NXX] with a date of 01/01/98
[MDN NPA-NXX] with a date of 01/03/99
I'm using a combo box to find the records. It searches fine, but will only populate the form with the first record even if I select the second record from the combo list. How can I select a specific record to populate the form?
Here's the query:
SELECT [altMASTER MDNMIN].[MDN NPA-NXX] FROM [altMASTER MDNMIN] ORDER BY [altMASTER MDNMIN].[MDN NPA-NXX];
Here's the event code:
Private Sub comboMDNsearch_AfterUpdate()
' Find the record that matches the control.
Dim rs As Object
Set rs = Me.Recordset.Clone
rs.FindFirst "[MDN NPA-NXX] = '" & Me![comboMDNsearch] & "'"
If Not rs.EOF Then Me.Bookmark = rs.Bookmark
Me![comboMDNsearch] = Null
End Sub
I appreciate your expertise, and thanks!
[MDN NPA-NXX] with a date of 01/01/98
[MDN NPA-NXX] with a date of 01/03/99
I'm using a combo box to find the records. It searches fine, but will only populate the form with the first record even if I select the second record from the combo list. How can I select a specific record to populate the form?
Here's the query:
SELECT [altMASTER MDNMIN].[MDN NPA-NXX] FROM [altMASTER MDNMIN] ORDER BY [altMASTER MDNMIN].[MDN NPA-NXX];
Here's the event code:
Private Sub comboMDNsearch_AfterUpdate()
' Find the record that matches the control.
Dim rs As Object
Set rs = Me.Recordset.Clone
rs.FindFirst "[MDN NPA-NXX] = '" & Me![comboMDNsearch] & "'"
If Not rs.EOF Then Me.Bookmark = rs.Bookmark
Me![comboMDNsearch] = Null
End Sub
I appreciate your expertise, and thanks!