[AccessD] ADO Connection with password

jeffrey.demulling at usbank.com jeffrey.demulling at usbank.com
Mon Dec 3 11:34:36 CST 2007


Andy,

The following site should be able to help you -
http://www.connectionstrings.com/?carrier=access

Look for the OLE DB section

Jeffrey F. Demulling
Project Manager
U.S. Bank Corporate Trust Services
60 Livingston Avenue
EP-MN-WS3C
St. Paul, MN  55107-2292
Ph: 651-495-3925
Fax: 651-495-8103
email: jeffrey.demulling at usbank.com


                                                                           
             "Andy Lacey"                                                  
             <andy at minstersyst                                             
             ems.co.uk>                                                 To 
             Sent by:                  "Dba"                               
             accessd-bounces at d         <AccessD at databaseadvisors.com>      
             atabaseadvisors.c                                          cc 
             om                                                            
                                                                   Subject 
                                       [AccessD] ADO Connection with       
             12/03/2007 09:52          password                            
             AM                                                            
                                                                           
                                                                           
             Please respond to                                             
             Access Developers                                             
              discussion and                                               
              problem solving                                              
             <accessd at database                                             
               advisors.com>                                               
                                                                           
                                                                           




Hi all

Does anyone else use the code, originally from JC IIRC, which shows who is
in an MDB by looking at the LDB? Well I've been successfully using this for
years but I now need it to work for a password-protected MDB. So I took the
lines


Dim cn As New ADODB.Connection
Dim cn2 As New ADODB.Connection

cn.Provider = "Microsoft.Jet.OLEDB.4.0"
cn.Open "Data Source=" & strDb

and changed them to:

cn.Provider = "Microsoft.Jet.OLEDB.4.0"
cn.Open "Data Source=" & strDb & "; Password=fred;"


but to no avail. I consistently get the message

"Cannot start your application. The workgroup information file is missing
or
opened exclusively by another user."

This is A97, and I do not use Access security. If I set the code back as it
was I'm told, rightly, that I need a password but I don't seem to be able
to
provide one. I guess the "workgroup information file" the message is
referring to is System.MDW but why does it have a problem with it? I've
tried copying the MDW from the System32 folder to where the MDB is. I've
tried copying the MDW from the folder where my live system lives to where
this MDB is. Neither helps. I'd appreciate any guidance on what's going on
here and what I'm doing wrong.

By the way 99.99% of my time I use DAO. This is ADO because, well because
that's the way this very clever code works. So my knowledge of ADO is very
.imited and I may therefore have made a very silly fundamental error. If so
do feel free to tell me.


--
Andy Lacey
http://www.minstersystems.co.uk

________________________________________________
Message sent using UebiMiau 2.7.2

--
AccessD mailing list
AccessD at databaseadvisors.com
http://databaseadvisors.com/mailman/listinfo/accessd
Website: http://www.databaseadvisors.com



U.S. BANCORP made the following annotations
---------------------------------------------------------------------
Electronic Privacy Notice. This e-mail, and any attachments, contains information that is, or may be, covered by electronic communications privacy laws, and is also confidential and proprietary in nature. If you are not the intended recipient, please be advised that you are legally prohibited from retaining, using, copying, distributing, or otherwise disclosing this information in any manner. Instead, please reply to the sender that you have received this communication in error, and then immediately delete it. Thank you in advance for your cooperation.



---------------------------------------------------------------------



More information about the AccessD mailing list