PRB: Error: Couldn't Lock File SHARE.EXE Hasn't Been LoadedID: Q110732
|
Trying to use a Microsoft Access Database that is located on a Read-Only
Share or Network Drive might generate the following error:
Couldn't lock file SHARE.EXE hasn't been loaded.
When Visual Basic tries to connect to a Microsoft Access database, an .LDB
file is created or the existing .LDB is used in the Database directory.
The .LDB file is used to assist in the management of the file locking
mechanism with multiple users. This file must be in the same directory as
the database and the file or directory must have Read/Write access or the
above error is generated.
This happens because the Microsoft Access engine in Visual Basic cannot
create or write to the necessary .LDB file.
To prevent the use or creation of the .LDB file, open the database
Exclusive use and Readonly (because of the read-only attribute of the
server) access. This tells the Microsoft Access Engine that the database
will be opened for single user only and that the .LDB file will not be
necessary.
If the multi-user access needed is read-only access, users do not have to
have read/write access to the LDB file. They only need read/write access if
they want to change the database. In reality, you can have each user open a
read-only database for exclusive access and no error would be generated. In
fact, this is what you need to do in Visual Basic for it to open an Access
database by multiple users on a read-only network drive or CD-ROM drive.
This behavior is by design.
Additional query words: 3.00 4.00 vb4win vb416
Keywords :
Version :
Platform :
Issue type :
Last Reviewed: June 10, 1999