Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Inactivity Timer
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Divers
Thread ID:
00009354
Message ID:
00009482
Vues:
48
>>>>>How can you know if something (anything) happend in the application from the timer?
>>
>>>??!
>>
>>Vlad
>>
>>Do a loop with the timer contained in it. The timer will expire and the loop will cycle. At this point the system should check resources. Another trick is to check system time against the value when you started. This way you can timeout after (ie) 15 minutes of inactivity.
>>
>>Tom
>
>I'm sorry, but I can't follow you.
>So, I have a timer object and I know when the application was started.
>Can you tell me exactly what tests I must do in the timer event to know that my app is active or inactive.
>
>How can I know that in the last, let's say 15 minutes, the user pressed a key, or moved the mouse, or launched a report or a query, etc., etc.
>
>The problem is not to close the app in any condition. The app should be closed only if is inactive for a specified time.

Vlad

Call a method you made (ie) MyTimer(). Loop & in the loop check a property you make (ie) KillTimer (among others). Have the KeyPress() method set the value of KillTimer.

HTH
Tom
Tom
--------------------------------
Tom O'Hare
407-299-4268 -- tom@redtile.com -- http://www.redtile.com/
Independent Programmer Using Visual FoxPro, Visual Basic & more...
Operations Manager -- Virtual FoxPro User Group (VFUG)
http://www.vfug.org/ -- tom@vfug.org
President -- Central Florida FoxPro User Group (CFFUG)
http://www.redtile.com/foxpro/
Universal Thread Most Valued Professional (MVP)
http://www.transformation.com/foxpro/
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform