[python-win32] HookMessage failure?
nanotube at gmail.com
Thu Apr 7 06:47:40 CEST 2005
the correct mesage to hook is "win32con.WM_LBUTTONDOWN"
try it with this one, and see if that works.
On 7 Apr 2005 02:15:41 -0000, b6y9eq902 at sneakemail.com
<b6y9eq902 at sneakemail.com> wrote:
> I'm currently trying to detect all clicks to a particular windows application, using win32gui and win32ui. Right now I'm using EnumWindows() to find the hwnd I want via window title, and then CreateWindowFromHandle(hwnd) to get a PyCWnd object that represents the window. I then attempt to use HookMessage() to set up a callback for win32con.LBUTTON_DOWN. However, my callback never gets called. I know I'm getting the right PyCWnd object, because I can use it to set/get the window title, but for some reason the callback function never gets called. Any ideas?
> Thanks, -Mark
> Python-win32 mailing list
> Python-win32 at python.org
More information about the Python-win32