Hi all! I keep getting a runtime error when i click
the cmdPrevious button but for some reason when the
Next Button is clicked there is no runtime error generated?
Why is that. And when the last record is reached no msgbox pops up. Why is that? Thanks


Private Sub cmdNext_Click()
Set db = OpenDatabase("C:\ToolBox\CompanyInventory97.mdb")
Set rs = db.OpenRecordset("ProductDecrption")
If rs.EOF Then
MsgBox "This is the end of the records"
Else
rs.MoveNext
txtProductID.Text = rs![Product ID]
txtName.Text = rs!Name
txtColor.Text = rs!Color
End If
rs.Close
End Sub


Private Sub cmdPrevious_Click()
Set db = OpenDatabase("C:\ToolBox\CompanyInventory97.mdb")
Set rs = db.OpenRecordset("ProductDecrption")
If rs.BOF Then
msbox "This is BOF"
Else
rs.MovePrevious
txtProductID.Text = rs![Product ID]
txtName.Text = rs!Name
txtColor.Text = rs!Color

rs.Close
End Sub