Results 1 to 9 of 9
  1. #1
    Join Date
    Oct 2003
    Location
    Boston, Mass. USA
    Posts
    81

    Unanswered: Check for inactivity and close mdb?

    I am responsible for a multi-user database where we are having some recordlocking problems. Often one of the tables locks and won't allow any users to write to it until everyone has closed and the LDB file has refreshed, no simple task with 20+ users. I am working on various means of resolving and preventing this since we cannot immediately convert to SQL.

    One problem is that users often leave the database, and sometimes forms open when away from their desk. Sometimes even overnight. This despite being repeatedly, kindly asked not to do so Due to client confidentiality, users have password screen savers making it difficult to refresh the LDB file or even do maintenance or troubleshooting, sometimes even after hours. .

    I would like to add some code that will periodically check for inactivity and if the user has not been active in the MDB for say 10-15 minutes, to automatically close the MDB.

    There is one form a menu that opens from the autoexec macro and stays open most of the time. Besides that there is a main data entry from which is where most of the time is spent, excepting for occasional report printing.

    Any suggestions on how to code this and what object(s) to put the code in and even how long to set the time-out (5, 10, 15 minutes?) would be appreciated.

    Mark
    Last edited by mdr02125; 11-21-03 at 16:25.

  2. #2
    Join Date
    Nov 2003
    Posts
    267
    I don't know if that is possible, but


    What I would do is change the way your program runs:

    I would have the interface (forms, reports, etc) in a DB seperate from the one where the actual data (tables reside). If you are using bound forms, don't. They leave recordsets tied up as long as they are open. Using unbound forms, open your DB connection, only when you need it and close it immediately after you are done with it.

    These items make it so that the only time you will lock a record is when you are actually reading from or writing to the database.

    Hopefully someone else will be able to answer you specific question, but I would still do this either way.

    Good luck

    S-

  3. #3
    Join Date
    Aug 2003
    Location
    Argentina
    Posts
    465
    If you have a local network i have a program in Access and a .Dll that can say to you who is login in the base.
    If you want i send to you.
    Saludos
    Norberto

  4. #4
    Join Date
    Oct 2003
    Location
    Boston, Mass. USA
    Posts
    81
    Thank you, Norberto, could you please send it? We have a Front and back end, novell network and win98/win2000. The ldb file doesn't seem to refresh fast enough to say who is really in it at the moment which makes for much frustration (not a lot of IT support here either).

    sbaxter, thanks, too. We do ahve a front and back end. I got confused by the terminology on bound forms vs. unbound, since I am more familiar with the objects in a form being bound vs. unbound.
    It uses optimistic locking (Record Locks = No locks) with Recordset Type= Dynaset. i've beenrunning this 20+ user heavy use database about 4 years and still am hazy on the terminology of how a form itself is bound/unbound, please forgive me Access 97 was easier for this, even if you didn't have much vba functionality.

    Mark

  5. #5
    Join Date
    Aug 2003
    Location
    Argentina
    Posts
    465
    Originally posted by mdr02125
    Thank you, Norberto, could you please send it? We have a Front and back end, novell network and win98/win2000. The ldb file doesn't seem to refresh fast enough to say who is really in it at the moment which makes for much frustration (not a lot of IT support here either).

    sbaxter, thanks, too. We do ahve a front and back end. I got confused by the terminology on bound forms vs. unbound, since I am more familiar with the objects in a form being bound vs. unbound.
    It uses optimistic locking (Record Locks = No locks) with Recordset Type= Dynaset. i've beenrunning this 20+ user heavy use database about 4 years and still am hazy on the terminology of how a form itself is bound/unbound, please forgive me Access 97 was easier for this, even if you didn't have much vba functionality.

    Mark
    I send to you two tool for user locks one in Access and other for general
    use, and a document for installing.
    Is important to read the document for installing, is in english.
    Attached Files Attached Files
    Saludos
    Norberto

  6. #6
    Join Date
    Jul 2003
    Posts
    81
    You could use the timer event procedure.

  7. #7
    Join Date
    Oct 2003
    Location
    Boston, Mass. USA
    Posts
    81
    Norberto,

    thanks! I had seen this documentation elsewhere - I think on Microsoft.com but not known where to get the DLL and exe files

    From the documentation, it appears to be written for older versions of Access and WIndows. I did get it to run at home with Win XP and Access 97, but is there anything you know that I should be aware of about running it on Win 98 and 2000 with Access 2000 and Access 2002?

    Thanks,
    Mark

  8. #8
    Join Date
    Aug 2003
    Location
    Argentina
    Posts
    465
    Originally posted by mdr02125
    Norberto,

    thanks! I had seen this documentation elsewhere - I think on Microsoft.com but not known where to get the DLL and exe files

    From the documentation, it appears to be written for older versions of Access and WIndows. I did get it to run at home with Win XP and Access 97, but is there anything you know that I should be aware of about running it on Win 98 and 2000 with Access 2000 and Access 2002?

    Thanks,
    Mark
    I use in : Windows 98 Second Edition.
    Access 97 Profesional Edition.
    Access XP
    If work for this i thing that work for Windows XP too.
    Is important that copy the DLL file to WINDOWS\SYSTEM in each Pc of the Network, where you want run the program.
    Saludos
    Norberto

  9. #9
    Join Date
    Oct 2003
    Location
    Boston, Mass. USA
    Posts
    81
    Gracias!

Posting Permissions

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