[Okta Webinar] Learn how to a build a cloud-first strategyRegister Now

x
?
Solved

Access Form_OnTimer - doesn't run during Hybernation??

Posted on 2006-03-28
12
Medium Priority
?
266 Views
Last Modified: 2012-06-21
I have a timer that checks for a value in a table... then if it's their, it shuts down access and kicks the users out. It works perfect, until the users machine goes to sleep or hybernates... then my "KickEmOut" utility is useless because the timer stops working?
Any Ideas?
0
Comment
Question by:a260148
  • 5
  • 4
  • 2
  • +1
12 Comments
 
LVL 58

Expert Comment

by:harfang
ID: 16316396
Hello,

I'm sorry, but I'm quite certain that there is no solution. While the computer sleeps, let alone hibernates, the entire Access process is stopped. You would need some form of wake-up call from the outside.

There might be a way to prohibit sleeping or hibernating while your application is open, but this will probably be quite version-specific. Perhaps try to ask "how to prevent sleeping and/or hibernating while my application is open" in a Window TA?

Good luck!
(°v°)
0
 

Author Comment

by:a260148
ID: 16316415
I'm in a work evironment that is very security driven... so that will not be a feasible option. If we leave our desks for longer than 15 minutes... they hybernate, lock, and you have to have a pw to log back in.
0
 
LVL 39

Expert Comment

by:thenelson
ID: 16316599
>If we leave our desks for longer than 15 minutes... they hybernate, lock, and you have to have a pw to log back in.
That is not the normal way that is handled.  Normally, the desktop just locks down after a period of inactivity but software will continue running underneath.  If that were the case, your database timer would run underneath the lock.  But if the computer truely goes into hibernation or sleep, you are completely out of luck.  Hibernation is identical to turning off the computer except memory is saved to disk before hibenation and then returned after hibernation.  Standby is the same as turning off the computer except power is maintained to the memory refresh circuits to keep memory alive.  It would be very unlikely that your database would run with the computer turned off.  

You could possibly determine when the computer is going into hibernation or standby with an API call and shut down Access then.  I will look into it.
0
Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 44

Expert Comment

by:Leigh Purvis
ID: 16316675
Not a fan of it (I know Nelson is - so shant berate it too much ;-) but might you not be able to use a Sendkeys to prevent your machine from dropping out at all?
Lure the pc into a continued sense of operation - allowing your application to continue doing its thing.

Obviously it would have to be something truly innocuous - like
SendKeys "^1"
(Asuming that ctrl + 1 doesn't ahve a specific meaning in your environment).

As I say though - not exactly jumping up and down about it as a possible solution :-)
0
 
LVL 39

Accepted Solution

by:
thenelson earned 500 total points
ID: 16316681
0
 

Author Comment

by:a260148
ID: 16316699
Are you saying that using the sendKeys would keep the machine from hybernating... ? I've never used the sendkey... hmmm.
What if the use hit the hybernate key on the keyboard rather than just going after non-use?
0
 
LVL 44

Expert Comment

by:Leigh Purvis
ID: 16316828
Well what if they kick the wall socket switch while flirting with the person in the next cubicle.
There's no allowing for User umm... nuances (shall we say).
:-)
0
 
LVL 39

Expert Comment

by:thenelson
ID: 16324491
Hey, Leigh.  I never said I was a fan of SendKeys.  I've just said it can be useful at times (unlike our president George II) if used carefully.
0
 
LVL 44

Expert Comment

by:Leigh Purvis
ID: 16325625
Nah - I saw you on TV at a SendKeys rally.
Waving a banner - chanting.
"Hurrah for Sendkeys!"
:-p

Ahh - knowing you perhaps you were only there for the scantily clad Sendkeys babes...
(Hey they should actually have those - and others at IT conferences and such.  You could whisper to your buddy "Wow - look at Miss DAO..." to which he would obviously reply "Nah - I prefer Miss ADO" etc etc and hilarity ensues)


(Point taken though - it's true what you say :-)
0
 
LVL 39

Expert Comment

by:thenelson
ID: 16326147
Miss DAO is hot!!  Have yous seen here with that little d that hardly covers anything?
0
 
LVL 39

Expert Comment

by:thenelson
ID: 16405736
At EE, a C grade is a failing grade (below is from http://www.experts-exchange.com/Databases/MS_Access/help.jsp#hi73):
C: Because Experts' reliability are often judged by their grading records, many Experts would like the opportunity to clarify if you have questions about their solutions. If you have given the Expert(s) ample time to respond to your clarification posts and you have responded to each of their posts providing requested information; or if the answers, after clarification, lack finality or do not completely address the issue presented, then a "C" grade is an option. You also have the option here of just asking Community Support to delete the question.

Could I ask you to either request community support (http://www.experts-exchange.com/Community_Support/) to delete the question and refund your points or up the grade? (below is from http://www.experts-exchange.com/Databases/MS_Access/help.jsp#hi71):
Before you ask the Moderators to help you in this circumstance, take the time to post a message in your question stating your intention to have the question deleted or closed, and make sure you have responded to all of the Experts' comments. Then post a question in the Community Support topic area asking the Moderators to delete your question. Remember to post a link to the original question in your request. If there are no comments in the question, one of the Moderators will delete the question. If there are comments, the Moderator will post notice of your request, and will give the participants 96 hours to object. You may be required to post your reason for asking for the deletion, and objections will be taken into account.

Thanks
0
 
LVL 44

Expert Comment

by:Leigh Purvis
ID: 16405906
And even "you can't do that" (and indeed occasionally a simple "No") is still a valid answer.

Although we might not want to hear it - doesn't make it less right.  :-)
0

Featured Post

Windows Server 2016: All you need to know

Learn about Hyper-V features that increase functionality and usability of Microsoft Windows Server 2016. Also, throughout this eBook, you’ll find some basic PowerShell examples that will help you leverage the scripts in your environments!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

We live in a world of interfaces like the one in the title picture. VBA also allows to use interfaces which offers a lot of possibilities. This article describes how to use interfaces in VBA and how to work around their bugs.
Windows Explorer let you handle zip folders nearly as any other folder: Copy, move, change, and delete, etc. In VBA you can also handle normal files and folders, but zip folders takes a little more - and that you'll find here.
In Microsoft Access, when working with VBA, learn some techniques for writing readable and easily maintained code.
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

873 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question