Hi guys... I'm trying to make a sample program that views the records from the database like the output above. I am using visual basic 6.0 and Access... With DataControl, I'd like to view the next records of the specific ID Number, by clicking on the Next button. My problem with the code below is the records with other ID Number are appearing...
Private Sub cmdNext_Click()
With Me.dtaInfo.Recordset
.MoveNext
Me.txtCash.Text = .Fields("Cash")
Me.txtAddress.Text = .Fields("Country")
End With
End Sub
Private Sub cmdShow_Click()
With Me.dtaInfo.Recordset
.Index = "idxIDNumber"
.Seek "=", Me.txtIDNumber.Text
Me.txtCash.Text = .Fields("Cash")
Me.txtAddress.Text = .Fields("Country")
End With
End Sub
Here's my records