Article View: borland.public.cppbuilder.nativeapi
Article #611WM_COPYDATA
From: Marshall Lawrence
Date: Fri, 07 Mar 2008 03:27
Date: Fri, 07 Mar 2008 03:27
26 lines
1901 bytes
1901 bytes
Ok, I have created an application that has several forms. On the 3rd form a button allows the user to start another application. When the application finishes it sends a message, SendMessage() to the handle of the program that called it. I have added a BEGIN_MESSAGE_MAP VCL_MESSAGE_HANDLER(WM_COPYDATA, TMessage, MWL); END_MESSAGE_MAP(TForm); in the 3rd forms .h file and the MWL() is declared and implemented in the 3rd forms files. However, using FindWindow(NULL, "geoloc") returns the handle to the program that contains the 3rd form and if I use that handle in the SendMessage() function, my message handler never fires and the programs hang because the message is not handled. So, PROGRAM A-->3rd FORM-->starts the execution of -->PROGRAM B... PROGRAM B-->Executes and just before exiting-->SendMessage() to PROGRAM A-->3rd FORM and the message is never handled and the whole thing hangs. Any help. Thanks, Marshall
Technical Details
Message-ID:
<47d0b606@newsgroups.borland.com>Path:
arc1-ca.pugleaf.net!g2news1.google.com!news4.google.com!feeder1-2.proxad.net!proxad.net!feeder1-1.proxad.net!club-internet.fr!feedme-small.clubint.net!newsfeed.freenet.de!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mailShow Full Headers
Complete Article Headers
X-Google-Thread: 10cc67,e373581945dbec23,start X-Google-Attributes: gid10cc67,public,usenet X-Google-Language: ENGLISH,ASCII-7-bit From: "Marshall Lawrence" <someone@microsoft.com> Newsgroups: borland.public.cppbuilder.nativeapi Subject: WM_COPYDATA Date: Thu, 6 Mar 2008 22:27:02 -0500 Lines: 28 X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 6.00.2900.3138 X-RFC2646: Format=Flowed; Original X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.3198 NNTP-Posting-Host: 74.235.221.116 Message-ID: <47d0b606@newsgroups.borland.com> X-Trace: newsgroups.borland.com 1204860422 74.235.221.116 (6 Mar 2008 19:27:02 -0700) Path: arc1-ca.pugleaf.net!g2news1.google.com!news4.google.com!feeder1-2.proxad.net!proxad.net!feeder1-1.proxad.net!club-internet.fr!feedme-small.clubint.net!newsfeed.freenet.de!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail