开发者

Cannot get data in MS Access database

I have an Access database stored on PC A, and an application located on PC B and C. When the application loads the data from the database, the error message "The Microsoft Jet database engine cannot open t开发者_运维技巧he file '\xxx.xxx.xxx.xxx\FolderName\Test.mdb'. It is already opened exclusively by another user, or you need permission to view its data." appears. However, if I open the database file by browsing from PC B one time and close it, the application can load the data without error and so the same as PC C.

The PCs are linked in peer to peer, and the app is desktop application. Could anyone give me any solution to load the data without opening the database file once?

Thank you.


This could be due to the application not closing properly the last time it was used. Check to see if there is an ldb (lock file) in the same directory as the database. Open it with a text editor and you can see who the last person to use the db was. If the db was not closed properly it may still be locked.


On a peer to peer network you need to set the permissions to Full control. Users need to be able to create and delete the LDB file. On a file server the detailed permissions would be something like read, write, create and delete.


sharing an Access database on a network (MDB)

To share an access database, just place the *.MDB file into a network share and open it across the network.


This sounds like a networking issue to me. If you've linked your table with a UNC name (apparently using an IP address, which is pretty inadvisable, unless it's a hardwired IP address that can't change), that's good, but a mapped drive can have one advantage if you set it to reconnect at logon (instead of reconnecting only when data on it is requested), and that is that the connection to the "server" PC is already initialized at the time you first request it through Access. If it's not, it can cause slowdowns and erroneous error messages.

Another option would be to add in the Autoexec.bat of the client PCs:

  NET USE \\xxx.xxx.xxx.xxx\FolderName

You don't have to map it to to a drive letter, just declare it as available. This would accomplish the same thing as an auto-reconnecting mapped drive, but there is no GUI for setting it up (as there is with mapping a drive).

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜