I need some help on how write SetWindowsHookE x in vb.net 2005 to hook kb input.
this is the statement:
hHOOKKb = SetWindowsHookE x( _
WH_KEYBOARD, _
lpfn, _
hMod, _
dwThreadId)
And this is from MSDN Library:
lpfn [in] Pointer to the hook procedure.
"hMod [in] Handle to the DLL containing the hook procedure pointed to
by the lpfn parameter."
"dwThreadId [in] Specifies the identifier of the thread with which the
hook
procedure is to be associated."
To get kb events from another thread, outside my program or from any desktop
thread should I put the hook procedure in a DLL (a separate module.vb)? And
if so how do I get its Handle and lpfn?
Thanks.
--
bruno
this is the statement:
hHOOKKb = SetWindowsHookE x( _
WH_KEYBOARD, _
lpfn, _
hMod, _
dwThreadId)
And this is from MSDN Library:
lpfn [in] Pointer to the hook procedure.
"hMod [in] Handle to the DLL containing the hook procedure pointed to
by the lpfn parameter."
"dwThreadId [in] Specifies the identifier of the thread with which the
hook
procedure is to be associated."
To get kb events from another thread, outside my program or from any desktop
thread should I put the hook procedure in a DLL (a separate module.vb)? And
if so how do I get its Handle and lpfn?
Thanks.
--
bruno
Comment