in reply to Re: Windows 98: track the current user's idle time
in thread Windows 98: track the current user's idle time

Yes, I will :)

It's to shut down that shitting MSN Messenger. My sister sometimes just doesn't quit it, and then, when I take place here, MSN is still loaded and then I've to close it myself. I just want it to be closed when she leaves the computer.
  • Comment on Re: Re: Windows 98: track the current user's idle time

Replies are listed 'Best First'.
Re: Re: Re: Windows 98: track the current user's idle time
by BrowserUk (Patriarch) on Mar 23, 2004 at 22:18 UTC

    You could look at using Win32::API to monitor the activation of the screen saver using SystemParametersInfo with with an action of SPI_GETSCREENSAVERRUNNING to determine when the screensaver kicks in (assuming it is enabled) and use that as your que for doing whatever your going to do.

    You'd probably want to use something like Win32::Daemon or Win32::Daemon::Simple to put your script in the background, though it is probably easier to just right-click and exit:)


    Examine what is said, not who speaks.
    "Efficiency is intelligent laziness." -David Dunham
    "Think for yourself!" - Abigail