-
We are making an application that will read data from the cd .We're having a problem reading a ms access database from the cd. It keeps on displaying that the database has been exclusively opened by another user.
What seems to be the possible cause of this?
-
A database that is Read-only will give you that error. Since it's on a CD, and you usually can't write to a CD, maybe that's the problem.
------------------
Marty
[This message has been edited by MartinLiss (edited 01-13-2000).]
-
Also if you have opened the file in one form and not closed it.
-
Make sure also that if you are using the OpenDatabase method that you have set the Options variable to False
e.g.
Dim ODb as Database
Set ODb=OpenDatabase(YourDbPath,False,False,ConnectString)
Connect string is usually for passwords (";pwd=" & "YourPassword")
This would only happen though if the file is being used elsewhere (like Access itself is open or more than one copy of your app is running...)
Regards,
------------------
- Chris
[email protected]
If it ain't broke - don't fix it :)
[This message has been edited by chrisjk (edited 01-14-2000).]
-
When opening an access database, a locking file will be created in the same directory as the database (eg Mydatabase.ldb).
If the databse is on a cd, this isn't possible and an error is generated.
I don't know a solution for this.
-
Hi.
It seeme that the only way is to copy your .MDB to a Temp Dir, then open it, read it and finally Kill it :)
Good Luck.
-
It seems to me that you are chasing a very fast car!
If the database is on CD why don't you create a vb front end (on the CD) that uses any of the data access technologies to view the data. I say this because you cannot write data back to the CD anyway.
This will eliminate the *.ldb problem!
Hope this helps . . .
------------------
Matt G
Either [email protected]] or [email protected]
-
I'm not sure about this but...have you tried to open the DB for exclusive reading?
------------------
Jorge Ledo
[email protected]
Portugal