Automatic application termination

Post Reply
User avatar
cdmmaui
Posts: 653
Joined: Fri Oct 28, 2005 9:53 am
Location: The Woodlands - Dallas - Scottsdale - London
Contact:

Automatic application termination

Post by cdmmaui »

Hello, does anyone have a sample function that will automatically terminates an application if a user is not actively using the application. I need this function to automatically close the application in case a user forgets to close application at end of day so we can run of an automatic index routine. Thank you in advance for your help.

Regards,
*~*~*~*~*~*~*~*~*~*
Darrell Ortiz
CDM Software Solutions, Inc.
https://www.cdmsoft.com
User avatar
James Bott
Posts: 4654
Joined: Fri Nov 18, 2005 4:52 pm
Location: San Diego, California, USA
Contact:

Post by James Bott »

Darrell,

Here is an idea. Create a timer that checks the time of day every 30 mintues or so then if it is after a specified time, call wndMain():end().

James
User avatar
Silvio
Posts: 3107
Joined: Fri Oct 07, 2005 6:28 pm
Location: Teramo,Italy

Post by Silvio »

I hope I can help you ....

Code: Select all


Local oOut
Local nTime:=0
Local oWnd

define window oWnd
....

DEFINE TIMER oOut INTERVAL  60000 OF oWnd ;
             ACTION (  nTime ++, if ( nTime == 1,( MsgInfo( OemToAnsi("Version 1.0 ( Demostration )." + CRLF +;
                      "Author" + CRLF + "name_application" + CRLF +"End of demostration") ),oWnd:END()),))

      ACTIVATE TIMER oOut


ACTIVATE WINDOW oWnd


Best Regards, Saludos

Falconi Silvio
Post Reply