
Datacontrol for Password secured Access db
Here is what I have found to work... just an expansion on the previous
reply.. (Just a cut from one of my current functions.)
If Len(SecFile) Then
DBEngine.SystemDB = Data_Path + "system.mdw"
DBEngine.DefaultUser = Trim$(U_Info(Index).UID)
DBEngine.DefaultPassword = Trim$(U_Info(Index).Password)
End If
Set WSpace = DBEngine.Workspaces(0)
Set POSDB = WSpace.OpenDatabase(Trim$(InFile$), False, False, ";pwd=" +
U_Info(Index).Password)
Quote:
>I believe this will work. In the connect property of the data control
type:
> ;pwd = password
>where password is your password. This is a string and I believe it is
similar
>to the connect property used in the opendatabase method of dao.
>> I want to use a datacontrol on a Vb form that has access to a .mdb-file
that
>> has a database password. I know how to get access via Dao-code, but how
to
>> accomplish this when using a control ?
>> In the 'databasename property' I can only put the location/name of the
file
>> but no password...
>--
>*************************************************
>Robert Cox
>MarCo Instrumentation & Control Systems, Inc.
>Tel: (919) 859-1373 Fax: (919) 859-1352
>http://www.marco-ics.com
>*************************************************