Click here to Skip to main content
15,886,919 members
Articles / Programming Languages / VBScript

View active users in MS Access db / Mass Close a shared MDE file

Rate me:
Please Sign up or sign in to vote.
5.00/5 (3 votes)
27 Aug 2009CPOL 36.3K   1.4K   11   6
1st access app allows you to view what computers are currently connected to an access database. 2nd is an example of auto-closing instances of a shared mde file

Test Access Database

This is an access application that allows you to view what computers are currently connected to other access databases. 

Alternatively, you could just look at the LDB file that access creates, and contact each of those people to see who actually has it open... But since I've done the work, why not reap the benefits? =)

This definitely works for Access 2003. I'm not sure about other versions...

 

Auto-Close Example 

If you just have one problem database, you can also pull the code from this application to auto-close the database when you go in and set a flag on a table.     

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


Written By
Software Developer
United States United States
likes boardgames, computer games, and enjoys his .net programming job.

Comments and Discussions

 
GeneralIt stop at: cn.Open "Data Source=" & file Pin
dlovep17-May-11 15:07
dlovep17-May-11 15:07 
GeneralRe: It stop at: cn.Open "Data Source=" & file Pin
ColinBashBash18-May-11 3:15
ColinBashBash18-May-11 3:15 
GeneralRe: It stop at: cn.Open "Data Source=" & file Pin
dlovep18-May-11 15:53
dlovep18-May-11 15:53 
Nope, I didnt replace any values in the table, I just unrar it and open it.

I have only Windows XP 32bit and Office prof. 2003 on it, not even setup any work group/user group, havent touch any OLEDB reference at all.

I have only 5 references:

Visual Basic For Applications
Microsoft Access 11.0 Object Library
OLE Automation
Microsoft DAO 3.6 Object Library
Microsoft Activex Data Object 2.1 Library

Since I wish to check if any Active User using the Server-side's MDB. At first I was curious might be the office 2007's compatible viewer might cause some trouble, but even I test on another fresh machines, the results are same.
GeneralRe: It stop at: cn.Open "Data Source=" & file Pin
ColinBashBash19-May-11 3:23
ColinBashBash19-May-11 3:23 
GeneralRe: It stop at: cn.Open "Data Source=" & file Pin
dlovep19-May-11 18:00
dlovep19-May-11 18:00 
GeneralGreat Pin
GeniusD3-Mar-11 4:23
GeniusD3-Mar-11 4:23 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.