Free Lessons
Courses
Seminars
TechHelp
Fast Tips
Templates
Topic Index
Forum
ABCD
 
Home   Courses   TechHelp   Forums   Help   Contact   Merch   Join   Order   Logon  
 
Back to Access Forum    Comments List
Upload Images   @Reply   Bookmark    Link   Email   Next Unseen 
Auto close Database
Brent Rinehart 
        
6 years ago
What would be the easiest way to auto close a database that is left open on a user's computer? I would like the database to close after say 1 hour of no activity on any form.
Richard Rost  @Reply  
           
6 years ago
If the database is on your computer, you can do something like this:

Set db = GetObject("C:\MyDatabase.ACCDB")
db.Application.Quit


But that only works if it's on the same computer you're working on. Seldom helpful. The only two ways to close an application remotely is to either connect to their system using something like Remote Desktop OR have a timer form running on their system that checks a linked table for a value/command to close once every hour.

It's funny you ask this, because right now I'm working on a project to remotely update objects (tables, queries, forms, etc.) on databases across a network. It's working great and is about 95% complete. The only problem I'm having is with Modules. They're a pain. I'm getting ready to publish what I've completed so far with the caveat that Modules are still a work in progress. MOST updates are to forms, and that's what I've made sure is working well.

Adding the ability to remotely shut down a workstation would be handy. I'll add it to this project. Look for it in the next day or two. I'm calling it ObjectCopy because the purpose is to copy objects from a central shared folder down to workstations. They have to run an event timer form, but it can be made to stay in the background or only run on startup. In your case, you'd want to let it run continuously and check every hour.
Brent Rinehart OP  @Reply  
        
6 years ago
Good afternoon Richard sorry for the late response work has been hectic the front end database would be on everyone's computer backend is on the server i would like each persons front end to shut down on their computers with a timer event if there is no activity in the database on their machine within 1 hour is this possible  without removing into their system?
Richard Rost  @Reply  
           
6 years ago
It's easy to set up a timer event so that the system will shut down in an hour. Make a form that they can't close. Set the OnTimer event to the Quit command I gave you earlier. Set the TimerInterval to an hour. The hard part is the "if there is no activity" part. You could set a variable in the system somewhere that gets reset to zero every time they do something like click a button or add a record, but Access has no way of tracking activity. I would say pop up a form in their face every hour and say "the system will shut down in 30 seconds unless you click OK" and then OK will reset the clock and not shut down on them. Lots of ways to do this.
Richard Rost  @Reply  
           
6 years ago
I hoped to have my ObjectCopy database ready to be posted a few weeks ago, but I keep finding little bugs in it - and it's only a side project at this point so I work on it when I can. Forced remote shutdown of the database is on my list of things to add.
Brent Rinehart OP  @Reply  
        
6 years ago
Thats sound like that will work thank you i we give it a shot

This thread is now CLOSED. If you wish to comment, start a NEW discussion in Access Forum.
 

Next Unseen

 
New Feature: Comment Live View
 
 

The following is a paid advertisement
Computer Learning Zone is not responsible for any content shown or offers made by these ads.
 

Learn
 
Access - index
Excel - index
Word - index
Windows - index
PowerPoint - index
Photoshop - index
Visual Basic - index
ASP - index
Seminars
More...
Customers
 
Login
My Account
My Courses
Lost Password
Memberships
Student Databases
Change Email
Info
 
Latest News
New Releases
User Forums
Topic Glossary
Tips & Tricks
Search The Site
Code Vault
Collapse Menus
Help
 
Customer Support
Web Site Tour
FAQs
TechHelp
Consulting Services
About
 
Background
Testimonials
Jobs
Affiliate Program
Richard Rost
Free Lessons
Mailing List
PCResale.NET
Order
 
Video Tutorials
Handbooks
Memberships
Learning Connection
Idiot's Guide to Excel
Volume Discounts
Payment Info
Shipping
Terms of Sale
Contact
 
Contact Info
Support Policy
Mailing Address
Phone Number
Fax Number
Course Survey
Email Richard
[email protected]
Blog RSS Feed    YouTube Channel

LinkedIn
Copyright 2026 by Computer Learning Zone, Amicron, and Richard Rost. All Rights Reserved. Current Time: 5/1/2026 5:41:39 PM. PLT: 1s