Re: WM_COPYDATA ... what's inside?
- From: David Wilkinson <no-reply@xxxxxxxxxxxx>
- Date: Tue, 17 Jun 2008 11:02:06 -0400
..rhavin grobert wrote:
After reading something about WM_COPYDATA, i'm still unshure if i
should use it...
The question is: what does it do? M$ doesnt explaint this very well
(as expected ;-), so i see two possible ways how it is done:
#1 SendMessage(WM_COPYDATA, ...) copies the data in an internal buffer
and POSTS the message to the destination 'while' it returns (so it is
some kind of PostMessage anyway).
#2 SendMessage(WM_COPYDATA, ...) SENDS the pointer to the data or the
pointer to an internal copy of the data to the destination and returns
AFTER the message was processed (whitch would render it pretty useless
for me;-).
if #1 is true it would be easy to implement #2 atop of it, but if #2
is true, it would be completely useless for me, so perhaps someone
could please answer this...
..rhavin:
It's more like 2. Like any SendMessage() it does not return until the receiver has handled the message. But why is this bad for you? If you want, your receiver can copy the data, post a message to itself, and return immediately. The actual work can be done in the PostMessage() handler.
--
David Wilkinson
Visual C++ MVP
.
- Follow-Ups:
- Re: WM_COPYDATA ... what's inside?
- From: .rhavin grobert
- Re: WM_COPYDATA ... what's inside?
- References:
- WM_COPYDATA ... what's inside?
- From: .rhavin grobert
- WM_COPYDATA ... what's inside?
- Prev by Date: Re: Unable to link (static MFC)
- Next by Date: Re: Unable to link (static MFC)
- Previous by thread: WM_COPYDATA ... what's inside?
- Next by thread: Re: WM_COPYDATA ... what's inside?
- Index(es):
Relevant Pages
|