Hi guys
The following code works fine and it moves to the first record where QA is null. But I want to write code to move to next record now where QA is null.
Can anybopdy please help me to write code to move to next record?
Dim cn As ADODB.Connection
Dim rs As ADODB.Recordset
Dim r As Long
Set cn = New ADODB.Connection
cn.Open "Provider=Microsoft.Jet.OLEDB.4.0; " & _
"Data Source=J:\Capture.mdb;"
Set rs = New ADODB.Recordset
strsql = "Select ID,Batch_Number,Policy_Number,Received_Date,Processed_Date,Within_SLA,White_Mail,Unreadable_Data,Missing_Signature,Survey_Reference_Code,Name,Description,Address_Line1,Address_Line2,Address_Line3,Postcode from WLBaseDAta where isnull(QA)=true order by ID"
rs.Open strsql, cn
If Not (rs.BOF = True And rs.EOF = True) Then
rs.MoveFirst
ID = rs.Fields(0).Value
BNo = rs.Fields(1).Value
PNo = rs.Fields(2).Value
RDate = rs.Fields(3).Value
PDate = rs.Fields(4).Value
WSLA = rs.Fields(5).Value
WMail = rs.Fields(6).Value
UDate = rs.Fields(7).Value
MSig = rs.Fields(8).Value
SRC = rs.Fields(9).Value
txtName = rs.Fields(10).Value
Desc = rs.Fields(11).Value
Add1 = rs.Fields(12).Value
Add2 = rs.Fields(13).Value
Add3 = rs.Fields(14).Value
Pcode = rs.Fields(15).Value
End If
rs.Close
cn.Close
Thanks
Bookmarks