R
Robert
Contrary to MS documentation I cannot get a reference to
CurrentDB in an adp file.
1. I have set a reference to DAO 3.6 (as MS documentation
states) I even moved it above the ADO reference, I even
removed the ADO reference...no luck
2. I get "Object variable or with variable not set"
(error 91) when I run the following code. I get the error
on the last line (Debug.Print)
Sub test()
Dim db As DAO.Database
Set db = CurrentProject.Application.CurrentDb
Debug.Print db.Name
End Sub
Any help would be greatly appreciated.
CurrentDB in an adp file.
1. I have set a reference to DAO 3.6 (as MS documentation
states) I even moved it above the ADO reference, I even
removed the ADO reference...no luck
2. I get "Object variable or with variable not set"
(error 91) when I run the following code. I get the error
on the last line (Debug.Print)
Sub test()
Dim db As DAO.Database
Set db = CurrentProject.Application.CurrentDb
Debug.Print db.Name
End Sub
Any help would be greatly appreciated.