Here is the code:
Code:
Private Sub Form_Load()
Dim strCnn As String
Dim dbFac As DAO.Database
Dim db As DAO.Database
Dim rstFac As DAO.Recordset
Dim strError As String
Set db = OpenDatabase _
("C:\Projects\CustomReports\Hermann\ctx.mdb", _
False, False, "Ms Access;PWD=****")
Set rstFac = db.OpenRecordset("Hospitals", dbOpenSnapshot, dbReadOnly)
End Sub
[\code]
I am getting the error message "No read permissions on the table Hospitals." Does DAO open tables using the "Admin" user account by default??? Is that why this isn't working (admin account does not have any permissions)? We have applications that connect to these databases so must they have user id's that they use to connect to the database? How would I specify a user id??? Thanks in advance!