Sub TestAccess()
Dim db As DAO.Database
Dim rs As DAO.Recordset
Set db = DAO.DBEngine.OpenDatabase("D:\temp\Northwind.mdb", False, False, "MS Access;pwd=coco")
'Set db = DAO.DBEngine.OpenDatabase("D:\temp\Northwind.accdb", False, False, "MS Access;pwd=coco")
Set rs = db.OpenRecordset("Customers", dbOpenTable)
' Use the Recordset
Do While Not rs.EOF
Debug.Print rs.Fields("ContactName")
' Debug.Print rs.Fields("Last Name")
rs.MoveNext
Loop
' Clean up
Set rs = Nothing
Set db = Nothing
End Sub