Newsgroups : Borland : borland.public.delphi.nativeapi.win32 : 2005 Apr : Going nuts with messages and pointers
| Subject: | Going nuts with messages and pointers |
| Posted by: | "Loren Pechtel" (lorenpechtel@remove.hotmail.com) |
| Date: | 15 Apr 2005 22:36:07 |
I've got a thread doing some processing. When it finishes I want to post a message containing a pointer to the thread to notify the main thread that the thread is done and awaiting new work.
As the third parameter to PostMessage I'm sending Integer(@Self). In an older version I was sending a small number here and picking it up in wparam from the main thread no problem. However, now I'm getting a quite different value and I have no idea why. I stepped through the code generated by the PostMessage call to see what actually went on the stack and the only correspondance with what I'm getting back is the first byte is zero in both cases.