Opening a Secured Access Database
After you've secured the database, you can open it as usual if Admin has no password. If Admin has a password, you can still open the database, but you'll need to supply your username and password in the Logon dialog box.
You might also need to know how to get the database open using VBA code. To open the database using DAO, you would use code similar to this (don't forget to set a reference to the DAO object library first):
Dim wkspTempWorkspace As Workspace Dim strSecuredDB As String Dim strUserName As String Dim strPassword As String Dim dbSecureDB As DAO.Database Dim rsTableToOpen As DAO.Recordset
After declaring the necessary variables, tell VBA where to find the workgroup information file:
DBEngine.SystemDB ...
Get Managing Data with Microsoft® Excel now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.