Thread: Methods for detecting 'Computer not in use'

  1. #1
    Malum in se abachler's Avatar
    Join Date
    Apr 2007
    Posts
    3,195

    Methods for detecting 'Computer not in use'

    I'm writing a small security app that will wash the harddrive free space, btu I only want it to run when the computer isnt inuse. I can obviously detect use when my application recieves thigns liek keystrikes and mouse messages, but those only work when my application has focus or the mouse is over its window. Any ideas theories or wild ass guesses on other methods?

  2. #2
    Kernel hacker
    Join Date
    Jul 2007
    Location
    Farncombe, Surrey, England
    Posts
    15,677
    Have you thought about using the "screensaver" functionality? I have never looked at those, but could perhaps supply you with what you want.

    On the other hand, if you just set the priority low enough, it will run in the background and won't really affect other apps.

    --
    Mats
    Compilers can produce warnings - make the compiler programmers happy: Use them!
    Please don't PM me for help - and no, I don't do help over instant messengers.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Is anyone ever a computer scientist outside of college?
    By indigo0086 in forum A Brief History of Cprogramming.com
    Replies: 25
    Last Post: 08-31-2007, 09:26 AM
  2. upgrade computer ?
    By teeyester in forum Tech Board
    Replies: 4
    Last Post: 10-11-2003, 09:51 PM
  3. Regarding Undergraduate Computer Majors
    By UnregdRegd in forum A Brief History of Cprogramming.com
    Replies: 11
    Last Post: 10-04-2003, 11:55 AM
  4. Visual C++ restarts my computer!
    By Misi in forum Tech Board
    Replies: 5
    Last Post: 11-20-2002, 03:58 PM
  5. computer sex
    By Unregistered in forum A Brief History of Cprogramming.com
    Replies: 5
    Last Post: 09-17-2001, 07:09 PM