Results 1 to 5 of 5
  1. #1
    Join Date
    Jan 2012

    Unanswered: Closing database (Idle time)

    Hey guys,

    Is it possible to have the database automatically closed after a set period of idle time as in the user is not using the database?

  2. #2
    Join Date
    Sep 2011
    Provided Answers: 2

    Close database

    I am working on similar idea but would like to log out user instead of closing database - unfortunately the menu item switch user is not exposed to scripts.Will try change user access action instead.
    Intended procedure:
    Create Global variable (math) called active.
    Set this variable to zero when ever any record selected - every form will need a script, also add line to most other scripts to zero variable.
    The idea is to maintain variable at zero while any database activity.
    Next create 2 timers - one running at 1 minute and incrementing variable by 1+current value and the other running at 10 minutes, so if "active" has reached say 10 then do some action (close , change etc) else if less then 10 do nothing.
    Have been in holding pattern waiting on V10 in case function "built in" but does not appear so.

  3. #3
    Join Date
    Jul 2012
    Provided Answers: 19
    Set this variable to zero when ever any record selected
    Very good idea.

    Food for thought. It will obviously totally depend on the nature of your databases use, but for many I've written the end user would have a single record open for upwards of an hour and actually using it while doing other things.

    That considered, you might also consider also adding that function to “On Edit” for each field of your form in order to keep the timer in check for real live activity and not just record selection.


  4. #4
    Join Date
    Feb 2004
    In front of the computer
    Provided Answers: 54
    A simpler option might be to set a "drop dead" time to "x minutes from now" every time that the user "does something of interest". Then you only need one routine to set the "drop dead" time (which can be called from everywhere), and one event to check and see if the "drop dead" time has past and take the appropriate action.

    For most of the applications that I've seen, logout is pretty simple. If that doesn't work easily, you could always exit from the program (drastic, but effective).

    In theory, theory and practice are identical. In practice, theory and practice are unrelated.

  5. #5
    Join Date
    Jan 2012
    Thanks guys! Will see what works best!

Posting Permissions

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