Solved

reading .mdb file with VB6

Posted on 1999-01-03
3
1,491 Views
Last Modified: 2008-03-03
How can I read a .mdb file with VB6. All permissions are set to default except the password. I can read it fine if I remove the password, but as soon as I add a password, My VB app can't access it anymore. Any ideas??
Albert
0
Comment
Question by:ahammar
3 Comments
 
LVL 23

Author Comment

by:ahammar
ID: 1972498
Edited text of question
0
 
LVL 7

Expert Comment

by:smilitaru
ID: 1972499
If you refer at user password you can set the default user and default password for opening workspace (see more on SystemDB property in help or Books online). If you refer at database password, I'm sorry but once I digged for that with no success.
0
 
LVL 1

Accepted Solution

by:
wdavidsmith earned 100 total points
ID: 1972500
For users to gain access to the secured objects in your database, DAO must have the location of this workgroup information file. The location can be identified to DAO either by specifying it in the Windows Registry or by setting the SystemDB property.

DBEngine.SystemDB = "c:\windows\system\system.mdw"

Dim dbsTheDatabase As Database
Set dbsTheDatabase = OpenDatabase("c:\folder\database.mdb")

For this option to have any effect, you must set the SystemDB property before your application initializes the DBEngine object (that is, before creating an instance of any other DAO object). The scope of this setting is limited to your application and can't be changed without restarting your application.

0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Most if not all databases provide tools to filter data; even simple mail-merge programs might offer basic filtering capabilities. This is so important that, although Access has many built-in features to help the user in this task, developers often n…
When you are entering numbers in a speadsheet, and don't remember what 6×7 is, you just type “=6*7" instead. It works in every cell! This is not so in Access. To enter the elusive 42 in a text box, you have to find a calculator, and then copy the re…
Using Microsoft Access, learn some simple rules for how to construct tables in a relational database. Split up all multi-value fields into single values: Split up fields that belong to other things into separate tables: Make sure that all record…
In Microsoft Access, when working with VBA, learn some techniques for writing readable and easily maintained code.

911 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

21 Experts available now in Live!

Get 1:1 Help Now