Article View: borland.public.cppbuilder.nativeapi
Article #643Re: How to use traditional Windows message and API function ?
From: nick
Date: Tue, 12 Feb 2008 11:22
Date: Tue, 12 Feb 2008 11:22
40 lines
2039 bytes
2039 bytes
Asger Joergensen <junk@Asger-P.dk> wrote:
>
>Hi nick
>
> nick says:
>>
>> (1) Receiving a message in application.
>> (2) I want application receiving a message and then display
>> some kind of infomation. I can do that in traditional Windows
>> API program but don't know how to do it in C++ builder. Thanks.
>
>In adition to what Dennis wrote.
>You can find the definations of the VCL messages in Messages.hpp,
>using the right message structure usually gives nicer code when
>using the message.
>
>e.g.
>void __fastcall TMyPanel::WMMouseMove(Messages::TWMMouse &Msg)
>{
> TPanel::Dispatch((void*)&Msg);
> //do things with Msg.XPos or Msg.YPos
>}
>
>Dispatch is used to make sure that the message is passed on to
>the ancestor. I most cases You must use Dispatch otherwise things
>don't work correctly.
>
>
>
>P.s. Please manually breake Your text lines, due to code lines
>most of us have turned of auto linebreak, which makes it hard
>to read when people don't break lines.
>
>Kind regards
>Asger
Thanks, very much for the help.
Nick
Technical Details
Message-ID:
<47b18f9c$1@newsgroups.borland.com>Path:
arc1-ca.pugleaf.net!g2news1.google.com!news4.google.com!news.germany.com!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mailReferences:
<47b02ecf$1@newsgroups.borland.com> <MPG.221a525c60a3d10c989a5f@newsgroups.borland.com> <47b0d385$1@newsgroups.borland.com> <MPG.221b6e643d745c66989a61@newsgroups.borland.com>Show Full Headers
Complete Article Headers
X-Google-Thread: 10cc67,985e142ee2266c4 X-Google-Attributes: gid10cc67,public,usenet X-Google-Language: ENGLISH,ASCII-7-bit From: "nick" <nileiqi@hotmail.com> Sender: "nick" <nileiqi@hotmail.com> Reply-To: "nick" <nileiqi@hotmail.com> Subject: Re: How to use traditional Windows message and API function ? Newsgroups: borland.public.cppbuilder.nativeapi X-User-Info: 122.107.131.15 References: <47b02ecf$1@newsgroups.borland.com> <MPG.221a525c60a3d10c989a5f@newsgroups.borland.com> <47b0d385$1@newsgroups.borland.com> <MPG.221b6e643d745c66989a61@newsgroups.borland.com> NNTP-Posting-Host: 207.105.83.66 Message-ID: <47b18f9c$1@newsgroups.borland.com> Date: 12 Feb 2008 04:22:52 -0700 X-Trace: newsgroups.borland.com 1202818972 207.105.83.66 (12 Feb 2008 04:22:52 -0700) Lines: 42 Path: arc1-ca.pugleaf.net!g2news1.google.com!news4.google.com!news.germany.com!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail