DAO (only for VBA!)

Walk through recordset

Dim db As Database
Dim strSQL As String
Dim rst As Recordset
Set db = CurrentDb
strSQL = "SELECT ContractGroup, ContractNumber FROM VosaAgree"
Set rst = db.OpenRecordset(strSQL)
Do Until rst.EOF
Debug.Print rst!ContractGroup & ", " & rst!ContractNumber
rst.MoveNext
Loop

Unless otherwise stated, the content of this page is licensed under Creative Commons Attribution-ShareAlike 3.0 License