There is one client, and it uses LoadLibrary to get the DLL (which installs a global keyboard hook).
As long as the client is in focus, the DLL can call a callback function which the client provides it with. If however the client is not in focus, the callback never returns.
The trouble is, what I understand from the MSDN, the DLL is duplicated many times (once for each running application) to handle the keyboard hooking....
User Profile
Collapse
-
...I hope this isn't off topic as it refers to DLLs. I would not find a Windows-specific programming forum on this site.
I suspect this question is less about DLLs and more about how to share data between applications using C++ (but perhaps even that is OS-specific) :(Leave a comment:
-
Dynamic Link Library & Function Pointers
Hello all. I'm writing a Push To Talk radio program. As such I have a DLL that uses SetWindowsHookE x to set a callback function. This works, and is called when keyboard events take place.
Client programs using this DLL wish to know when a keyboard event takes place (even if said client program is not in the foreground).
So in my DLL I store a function pointer in a shared data section), and the DLL allows the clients...
No activity results to display
Show More
Leave a comment: