PB with modeless app and global DLL keyboard hook 
Author Message
 PB with modeless app and global DLL keyboard hook

Hi,
I am using MSVC++6.0
I've created a global keyboard hook I have embedded in a DLL.
This DLL works fine with a dialog based application (modal) and I am
able to retrieve in real-time all keys strokes.
But here is my problem. I want to use this dll in a modeless
application.

In fact, I created an application hidden in the system tray, and when I
want to use this dll, i am unable to get the keys strokes... The dll
never sends to my application the keys the users typed in on the
keyboard!!! And did it at the perfection when i was using it a dialog
based app.

It appears the dll never call the ON_WM_COMMAND() procedure of my
MainFrame...
With this modeless app I am unable to retrieve on-the-fly all key
pressed even with a global keyboard hook (which should catch all keys,
even if the user types in another application like Word isn't it?).
If I override the PreTranslateMessage(), it works _only_ if my
application got the focus. If my app doesn't have focus (e.g. if I work
under a text editor), it is unable to hook keys...

Thank you for your help...I really don't know how to deal with this
problem.

Best Regards,
David Excoffier.
Remove "_ " to answer by mail.



Sun, 16 Jun 2002 03:00:00 GMT  
 
 [ 1 post ] 

 Relevant Pages 

1. Global Keyboard hook without DLL

2. HELP: Big Pb with modeless app and global kbd hook DLL...

3. HLP: Kbd Hook dll and MFC modeless app ???

4. Global Keyboard Hook Problem

5. system wide keyboard hook in MFC app

6. help pls on MFC DLLs and Global WH_SHELL hook

7. CFile in a dll with global hook??

8. Help - Global hook in DLL

9. Keyboard Hook DLL Problem

10. Interfacing VC++ dll and PB app.

11. Modeless Dialog in DLL, trying to pass calling APP as parent

12. FindWindow, dll and MFC modeless app?

 

 
Powered by phpBB® Forum Software