A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Access » New Users
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

Two users in the same database at the same time



 
 
Thread Tools Display Modes
  #11  
Old January 14th, 2010, 07:07 PM posted to microsoft.public.access.gettingstarted
Douglas J. Steele[_3_]
external usenet poster
 
Posts: 3,143
Default Two users in the same database at the same time

"David W. Fenton" wrote in message
36.89...
"Douglas J. Steele" wrote in
:

if you have code that relies on the non-existence of the file,
you'll run into problems...


In that case, you can convert your code to try to delete the LDB
file. If it's in use, you'll get a trappable error.


Even if you don't have Delete permission?

Or will it be a different error if it's in use than if it isn't?

--
Doug Steele, Microsoft Access MVP
http://I.Am/DougSteele
(no e-mails, please!)



  #12  
Old January 15th, 2010, 12:19 AM posted to microsoft.public.access.gettingstarted
David W. Fenton
external usenet poster
 
Posts: 3,373
Default Two users in the same database at the same time

"Douglas J. Steele" wrote in
:

"David W. Fenton" wrote in message
36.89...
"Douglas J. Steele" wrote in
:

if you have code that relies on the non-existence of the file,
you'll run into problems...


In that case, you can convert your code to try to delete the LDB
file. If it's in use, you'll get a trappable error.


Even if you don't have Delete permission?

Or will it be a different error if it's in use than if it isn't?


Good question!

Maybe the real way to do it is to actually not use the LDB file as a
proxy for someone having the MDB open, and instead use the Windows
API to check if the MDB is actually open:

http://vbnet.mvps.org/index.html?cod...file_inuse.htm

I can't endorse the code there (I've never used it), but it's a
start.

--
David W. Fenton http://www.dfenton.com/
usenet at dfenton dot com http://www.dfenton.com/DFA/
 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump


All times are GMT +1. The time now is 09:58 PM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.