Article View: borland.public.cppbuilder.nativeapi
Article #4266Re: Continuing problem with SendMessage and WM_CCOPYDATA
From: Nate
Date: Mon, 27 Feb 2006 19:18
Date: Mon, 27 Feb 2006 19:18
47 lines
2203 bytes
2203 bytes
I tried posting a reply using the web page inferface but don't
see it so I'll try again.
Bob Gonder <notbg@notmindspring.invalid> wrote:
>WM_MYMSG=RegisterWindowMessage("USDA.FS.FireScience.GooleEarthTool.Awake");
Made the change.
>> MyCDS.lpData = &pBuf; // address of the data
>
>You want a pointer to the data, not a pointer to a pointer to
the data.
> MyCDS.lpData = pBuf; // address of the data
Found the first instance in some posted code, tried it, and
forgot to change it back. It's been corrected.
>>// in my main form .h
>
>> // This function is never called...
>>void __fastcall TFormMain::WMCopyData(TWMCopyData &message)
>>{
>> if(message.CopyDataStruct->dwData == WM_MYMSG)
>> {
>> Application->Restore();
>> Show();
>
>Verify that it is never called, and not just called with
"incorrect"
>data:
> }else{ ShowMessage("WM_MYMSG is not correct");
>
OK, I should have done that rather than watch it in the
debugger. I made the change and tested it. ShowMessage is not
called.
The receiver addess is the handle to the application but the
receiver code is in the main form - does this matter?
What should SendMessage return on success?
Thanks
Nate
Technical Details
Message-ID:
<44035e7c$1@newsgroups.borland.com>Path:
arc1-ca.pugleaf.net!g2news1.google.com!news1.google.com!news2.google.com!news3.google.com!border1.nntp.dca.giganews.com!nntp.giganews.com!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mailReferences:
<44021981$1@newsgroups.borland.com> <2f36029db0t6k0taqhpch04dcvrm1832e5@4ax.com>Show Full Headers
Complete Article Headers
X-Google-Thread: 10cc67,6afbc9bf5041d787 X-Google-Attributes: gid10cc67,public X-Google-Language: ENGLISH,ASCII-7-bit From: "Nate" <RNLockwood@attglobal.net> Sender: "Nate" <RNLockwood@attglobal.net> Reply-To: "Nate" <RNLockwood@attglobal.net> Subject: Re: Continuing problem with SendMessage and WM_CCOPYDATA Newsgroups: borland.public.cppbuilder.nativeapi X-User-Info: 170.144.4.190 References: <44021981$1@newsgroups.borland.com> <2f36029db0t6k0taqhpch04dcvrm1832e5@4ax.com> NNTP-Posting-Host: 207.105.83.66 Message-ID: <44035e7c$1@newsgroups.borland.com> Date: 27 Feb 2006 12:18:04 -0700 X-Trace: newsgroups.borland.com 1141071484 207.105.83.66 (27 Feb 2006 12:18:04 -0700) Lines: 48 Path: arc1-ca.pugleaf.net!g2news1.google.com!news1.google.com!news2.google.com!news3.google.com!border1.nntp.dca.giganews.com!nntp.giganews.com!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail