|
-
Jun 29th, 1999, 04:59 PM
#1
Thread Starter
New Member
This is the second message, related to the same subject, that I have rewritten to me more clear.
Using VB6 and a data control:
I need to read a database which may be or not password protected and may be written in Access 2 or Access 97.
This code works fine:
Private Sub Form_Load()
Data1.Connect = ";UID=Admin;PWD=SERARES"
Dim dbs As Database
Set dbs = OpenDatabase("C:\venezia1\venezia1.mdb", False, False, "MS Access;PWD=SERARES")
Data1.DatabaseName = "c:\venezia1\venezia1.mdb"
Data1.RecordSource = "schede"
Data1.Refresh
End Sub
but if, and this is the case, the database to be accessed is on a CD and is of course
READ ONLY I get an error message saying that the database is already exclusively opened by another user or I have not the authorisation to open the file.
How can I resolve this problem?
Please give me some tips.
------------------
-
Jun 30th, 1999, 05:07 PM
#2
Lively Member
Not sure about this, but since opening an .mdb file causes you to create or use an .ldb file, it may be trying to create that file on the CD (which would be a problem). Is it possible to specify the location of the .ldb file other than in the location of the .mdb? That might do the trick.
Bash
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|