CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Page 2 of 2 FirstFirst 12
Results 16 to 18 of 18
  1. #16
    Join Date
    Jan 2006
    Location
    Fox Lake, IL
    Posts
    15,007

    Re: how to capture keypress event when window is not focused

    People try to hack many things.
    David

    CodeGuru Article: Bound Controls are Evil-VB6
    2013 Samples: MS CODE Samples

    CodeGuru Reviewer
    2006 Dell CSP
    2006, 2007 & 2008 MVP Visual Basic
    If your question has been answered satisfactorily, and it has been helpful, then, please, Rate this Post!

  2. #17
    Join Date
    Jan 2002
    Posts
    195

    Re: how to capture keypress event when window is not focused

    I can give you an example of an application that would need to capture the key_Down and key_Up events that is perfectly legitament. Say I wanted to be able to make any window a top most window using a hot key. FN+T for instance. The only way to do this would be to capture the Keypress event which would of course also give me the handle to the window that currently has focus. I could then set that window to a TopMost window. This would be a perfectly legit use of capturing the keypress event and would not have a window of its own. In fact it would also be extreamly handy.

  3. #18
    Join Date
    Jul 2001
    Location
    Sunny South Africa
    Posts
    11,284

    Re: how to capture keypress event when window is not focused

    Closed, just in case this gets out of hand

Page 2 of 2 FirstFirst 12

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