Good evening,

could some one help me please.
lParam is a pointer to a MSG structure, how can I store .hwnd to a variable to use it later, I have tried this but it gives me an error.

; == callback GetMessage function == ;

GMFunc proc Code:DWORD, wParam:DWORD, lParam:DWORD

mov edx, lParam
assume edx: PTR MSG
mov Handle, [edx].hwnd ; ERROR!!!
invoke PostMessage, OwnerHwnd, WM_PASSDATA, Handle, [edx].wParam
assume edx: NOTHING
invoke CallNextHookEx, GMHook, Code, wParam, lParam
GMFunc endp

how can I use edx without using assume ?
something like this or how ?

mov edx, lParam
== is a MSG Structure ?
== hwnd ?
== message ?
== wParam ?
== lParam ?

oops I forgot about the button click.
Can I know when a button has been clicked with a WH_GETMESSAGE hook, or do I have to subclassing the button

thank you for your time
Posted on 2003-02-17 23:04:32 by Jnrz
how can I use edx without using assume ?

Like this:

mov eax, [edx].MSG.hwnd

mov Handle, .hwnd ; ERROR!!!
It is erroring because you are trying to do a direct memory to memory transfer, you need to transfer it to a register first. It has nothing to do with your usage of the "assume" directive.
Posted on 2003-02-18 04:01:32 by sluggy
Oh my bad...
I got confused because of the thing
thanks sluggy
Posted on 2003-02-20 18:53:47 by Jnrz