Ok, I have been going through someone elses Access Database to try to make it work for the client it was originally designed for. The database is coded very poorly and I have to try to figure out what is going on. They needed to change the AuditNo field in a table to AuditDate. AuditNo used to be the primary key, but the table structure has changed somewhat. Anyway, I got rid of all the references to the AuditNo field. I went through all the modules and code within the form and found everything and recoded. However when I try to do Me.Refresf or Me.Form.Refresh I get a box that has a caption, "Enter Parameter Value", tblSupplierHWSW.AuditNo. And I have no idea where this AuditNo is coming from, is it some reference I cannot find or is this something deeper? I mean I even debugged and stepped through the code to try to catch the reference and it just errors on the Me.Refresh. Here is the code for reference:
Private Sub Combo119_AfterUpdate()
On Error GoTo Combo119_AfterUpdate
DoCmd.SetWarnings False
Dim AuditDate As Date
Dim CurRow As Integer
' Find the record that matches the control.
Dim rs As Object
Set rs = Me.Recordset.Clone
CurRow = CInt(Me![Combo119].Column(1))
AuditDate = Me![Combo119].Column(0)
rs.FindFirst "[AuditDate] = #" & AuditDate & "#" ' And "[ItemNo] = " & CurRow
If CurRow > 1 Then
rs.FindNext "[ItemNo] = " & CurRow
End If
Me.Bookmark = rs.Bookmark
Me.Refresh <----- Here it errors out
DoCmd.SetWarnings True
Exit Sub
Combo119_AfterUpdate:
MsgBox Error$
DoCmd.SetWarnings True
End Sub
Private Sub Combo119_AfterUpdate()
On Error GoTo Combo119_AfterUpdate
DoCmd.SetWarnings False
Dim AuditDate As Date
Dim CurRow As Integer
' Find the record that matches the control.
Dim rs As Object
Set rs = Me.Recordset.Clone
CurRow = CInt(Me![Combo119].Column(1))
AuditDate = Me![Combo119].Column(0)
rs.FindFirst "[AuditDate] = #" & AuditDate & "#" ' And "[ItemNo] = " & CurRow
If CurRow > 1 Then
rs.FindNext "[ItemNo] = " & CurRow
End If
Me.Bookmark = rs.Bookmark
Me.Refresh <----- Here it errors out
DoCmd.SetWarnings True
Exit Sub
Combo119_AfterUpdate:
MsgBox Error$
DoCmd.SetWarnings True
End Sub