I'm looking for a good website/websites that can explain the Recordset functions and how they work. Currently I'm wanting to understand the .FindNext function and how it works. I was under the impression it would find the next instance of the "filter" you gave it, and stop once it had found all of the instances. However, mine appears to just loop back to the top. Here is my code...
Code:
Set db = CurrentDb
Set rs = db.OpenRecordset("tblAudit", dbOpenDynaset)
rs.FindFirst "[A$EMPLOYEE_NUMBER] = " & emplID
Do While Not rs.EOF
vPosition = rs("JOB_NAME")
vPositionDate = rs("DOWNLOAD_DT")
If vPositionDate < vCurrPositionDate Then
If vPosition <> vCurrPosition Then
'Do whatever necessary
End If
End If
rs.FindNext "[A$EMPLOYEE_NUMBER] = " & emplID
Loop