SetWindowsHookEx
-
I'm having problems withm a global windows hook created with SetWindowsHookEx. The hook procedure is contained in a dll and the installation procedure for the hook is also contained in the same dll. I also have an application that links to the dll and calls the installation procedure. When the application is running the hook works fine, but as soon as I quit the application the hook dissapears. I have not unhooked the hook, but it seems to uninstall it anyway. I wanted to install the hook using the application and then have the application quit while the hook is still running, can I do this? Thanks.
-
I'm having problems withm a global windows hook created with SetWindowsHookEx. The hook procedure is contained in a dll and the installation procedure for the hook is also contained in the same dll. I also have an application that links to the dll and calls the installation procedure. When the application is running the hook works fine, but as soon as I quit the application the hook dissapears. I have not unhooked the hook, but it seems to uninstall it anyway. I wanted to install the hook using the application and then have the application quit while the hook is still running, can I do this? Thanks.
When you app exits, all DLLs it has loaded are unloaded. You'll need to keep your app running all the time, perhaps minimized to the tray. --Mike-- http://home.inreach.com/mdunn/ The preferred snack of 4 out of 5 Lounge readers.