0

Private Sub Command1_Click()
Set rs1 = DB.OpenRecordset("Table1", dbOpenDynaset)

If rs1.EOF = True Then
MsgBox "Record is Empty"
Else
MsgBox "Got IT"
rs1.MoveLast
If Not rs1.EOF Then rs1.MoveFirst

Do While Not rs1.EOF


If rs1!Name <> "" And rs1!age <> "" Then

Set rs2 = DB.OpenRecordset("SELECT Name FROM Table2 WHERE Name like '" & rs1!Name & "*' ;")
If rs2.EOF = False Then
List1.AddItem (rs2!Name)
End If
End If

rs1.MoveNext
Loop
End If

If i will run this code with the given david godz c from table1 and david godz cagayan from table 2 it will display a david godz cagayan in the list

but my problem is how am i suppose to output same david godz cagayan in the list if i where
give a david godz c. from table1 and david godz cagayan from table2.

by the way im using ms access.

3
Contributors
2
Replies
3
Views
8 Years
Discussion Span
Last Post by pnorten462
This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.