Extracting data from Access Database password protected

G

Guest

I've manage to extract the data from a database into excel, however now the
database is password protected. How can incorporate the password into the
code I have now. I know the code should go somewhere in this area. Thanks
for any help

Set DB1 =
DBEngine.Workspaces(0).OpenDatabase("s:\Cio\Techplan\Adams\Itdmgmt\A_Proj_Mgmt_Rpt\Reporting\Access Databases\Dai_ITMB Access2000.mdb")
Set RS1 = DB1.OpenRecordset("tblFTSAtrakHrs", dbOpenTable)
 
G

Guest

Do a search in VBA help for "opendatabase". Look at Opendatabase Method
(DAO). the last parameter CONNECT can contain a password.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top