CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 2 of 2
  1. #1
    Guest

    Minimising On Idle

    Hi all,
    If there is no user intervention to my application for a configured time, I need to minimise the application. My application does lot of Database updates that may take lot of time. The application should not minimise when it is doing such processing.
    Thanks
    Steve


  2. #2
    Guest

    Re: Minimising On Idle

    We do this very thing in our application...

    In order to do this, you need to do several things....

    You need a DLL that installs hooks to monitor the keyboard and mouse. When your main executable is run, you install the dll and a timer that lets you know how long it has been since your last key press or mouse movement. If you are over your timeout threshhold, you minimize. Do NOT install the timer in the DLL as timer resolution will not work properly in a DLL...pass the current time to the DLL when you load it....

    Note that this is NOT an easy thing to do...writing hooking dlls is tricky and you MUST do it correctly or your hook DLL may cause other apps that use hooks to fail and/or behave improperly.




Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured