Using ASP to close an Access Database

Results 1 to 2 of 2

Thread: Using ASP to close an Access Database

  1. #1
    Join Date
    Dec 1969

    Default Using ASP to close an Access Database

    Hi, I would like to write a routine to compact and repair an MS Access database nightly. The problem is, there are some residual connections out there and I can&#039;t get exclusive access to the file. Does anyone know how to close all open connections to an MS Access file using ASP or VB code? Your help is appreciated!!<BR><BR>-jb<BR>

  2. #2
    Join Date
    Dec 1969

    Default Not without a component...

    ASP users certainly have no "authority" whatsoever to close down any other users. That applies to other ASP users, even, not to mention non-ASP users.<BR><BR>If the only connections that are open on the DB are ASP-based, then you *might* be able to do this by setting an Application variable as a flag and all new users coming in will check the flag before trying to connect (and won&#039;t even try to connect if it&#039;s set). Then you just have to wait and wait until all existing users eventually disconnect.<BR><BR>If you wanted to be agressive about it, you could set the flag and then current ASP users couldn&#039;t even continue what they were doing until the compact/repair is completed.<BR><BR>But I see no solution for non-ASP users who are also hooked up.<BR><BR>

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts