WM_VSCROLL not working after starting a hook 
Author Message
 WM_VSCROLL not working after starting a hook

Hi all,

I've got a very strange problem :-)
I wrote the following message hook in VC++:

...
  g_hHookCallWndProc  = SetWindowsHookEx(WH_CALLWNDPROC,  MyCallWndProcHook,
hInst, 0);
...

LRESULT CALLBACK MyCallWndProcHook(int code, WPARAM wParam, LPARAM lParam)
{
  return ::CallNextHookEx(g_hHookCallWndProc, code, wParam, lParam);

Quote:
}

After calling this hook I cannot send any "SendMessage ctl.hWnd, WM_HSCROLL,
SB_LINELEFT, 0" to a control via VB.
Although  "SendMessage ctl.hWnd, WM_VSCROLL, SB_LINEDOWN, 0" works fine via
VB.

The same strange effect is appearing after starting Microsoft Spy++ instead
of the hook.

Another strange thing is, that I cannot send a WM_HSCROLL message to a text
box in VB although I can send an WM_VSCROLL message.
With VC++ I can send this event. What's going wrong?

Any ideas? Is this a bug?

Thanks from Germany,
Andreas



Mon, 20 Sep 2004 01:55:58 GMT  
 
 [ 1 post ] 

 Relevant Pages 

1. Global hook does not work in NT4

2. InStr Function does not work if start position is skipped

3. Start windows hook functions with Registry ?

4. Macro not starting when starting word 97 with /m command

5. VB hooks to WORD don't seem to work with Word 2000 SP1

6. Mhcallback - Keyboard hook and Mouse hook , HOW!

7. Windows hook and control hook

8. Word not beeing started (not fast enough)

9. entrymacro is not started if field not empty and clicked

10. Hooking Question,(and not the oldest profession :-) )

11. hooks and what not ....

12. WM_VScroll and SB_ThumbTrack code

 

 
Powered by phpBB® Forum Software