Can someone please examine the coding below and see if I have a syntax or logic error. I am using the filter on a form for my parameters in my recordset. The DCount statement finds 10 records, but rs1.EOF = TRUE after the open statement.
DCWhere = Forms!frmspecialpricingfilter!frmSpecialPricingEnt ryList.Form.Filter
StrMsg = MsgBox("You are about to add " & DCount("*", "tblSalesSpecialPricing", DCWhere) & " record(s).", vbOKCancel + vbDefaultButton2)
If StrMsg = vbCancel Then Exit Sub
' create new records
Dim Con1 As New ADODB.Connection, Con2 As New ADODB.Connection
Set Con1 = CurrentProject.Connection
Set Con2 = CurrentProject.Connection
Dim rs1 As New ADODB.Recordset, rs2 As New ADODB.Recordset
rs1.Open "SELECT * FROM tblSalesSpecialPricing WHERE " & DCWhere, Con1, adOpenDynamic, adLockPessimistic