Article View: borland.public.cppbuilder.nativeapi
Article #4503Re: Receiving NIN_BALLOONUSERCLICK from system tray balloon
From: JD
Date: Wed, 18 Jan 2006 12:21
Date: Wed, 18 Jan 2006 12:21
38 lines
2263 bytes
2263 bytes
Kris <x.y@xyz.xx> wrote:
>
Good catch by Vladimir with the NO_WIN32_LEAN_AND_MEAN
but I think he missed the problem with your message map
because he was thinking of my sample. Try this:
class TMainForm : public TForm
{
__published:
protected:
private:
MESSAGE void __fastcall NINBalloonUserClick(TMessage &Message );
public:
BEGIN_MESSAGE_MAP
VCL_MESSAGE_HANDLER( NIN_BALLOONUSERCLICK, TMessage, NINBalloonUserClick )
END_MESSAGE_MAP( TForm )
}
MESSAGE void __fastcall TMainForm::NINBalloonUserClick( TMessage &Message )
{
Caption="Click Balloon";
}
If this doesn't work, then it's because the wrong HWND is
getting the message. I don't have BDS (yet) so I can't look
at that component to tell you exactly what to do. What you
need is to associate that message map with the HWND or Handle
that the component is sending messages to.
Also note that I changed your definition of TMessage &Msg
because of TMsg. A TMsg parameter is different from a
TMessage parameter and while a parameter name is just a name,
you don't want to confuse them.
~ JD
Technical Details
Message-ID:
<43ce40cc$1@newsgroups.borland.com>Path:
arc1-ca.pugleaf.net!g2news1.google.com!news2.google.com!news4.google.com!border1.nntp.dca.giganews.com!nntp.giganews.com!newshub.sdsu.edu!pln-w!lotsanews.com!news-out.newsgroups.com!propagator2-sterling.newsfeeds.com!in.nntp.be!caladan.landsraad.net!newsgroups.borland.com!not-for-mailReferences:
<0dbqs15pnttts94lrl0gfkv1qmdi5r7v2g@4ax.com> <43cd446a$1@newsgroups.borland.com> <etiqs1l4jrqdiv9tmdtvn21ea51agjh5rr@4ax.com> <43cd4df1$1@newsgroups.borland.com> <4rjqs1tm8kga0600i4ifonpfa0erubkh7l@4ax.com>Show Full Headers
Complete Article Headers
X-Google-Thread: 10cc67,2165941223f42fca X-Google-Attributes: gid10cc67,public X-Google-Language: ENGLISH,ASCII-7-bit From: "JD" <nospam@nospam.com> Sender: "JD" <nospam@nospam.com> Reply-To: "JD" <nospam@nospam.com> Subject: Re: Receiving NIN_BALLOONUSERCLICK from system tray balloon Newsgroups: borland.public.cppbuilder.nativeapi X-User-Info: 205.188.116.136 X-Forwarded-For: 172.134.247.138 References: <0dbqs15pnttts94lrl0gfkv1qmdi5r7v2g@4ax.com> <43cd446a$1@newsgroups.borland.com> <etiqs1l4jrqdiv9tmdtvn21ea51agjh5rr@4ax.com> <43cd4df1$1@newsgroups.borland.com> <4rjqs1tm8kga0600i4ifonpfa0erubkh7l@4ax.com> NNTP-Posting-Host: 207.105.83.66 Message-ID: <43ce40cc$1@newsgroups.borland.com> Date: 18 Jan 2006 05:21:16 -0700 X-Trace: newsgroups.borland.com 1137590476 207.105.83.66 (18 Jan 2006 05:21:16 -0700) Lines: 39 Path: arc1-ca.pugleaf.net!g2news1.google.com!news2.google.com!news4.google.com!border1.nntp.dca.giganews.com!nntp.giganews.com!newshub.sdsu.edu!pln-w!lotsanews.com!news-out.newsgroups.com!propagator2-sterling.newsfeeds.com!in.nntp.be!caladan.landsraad.net!newsgroups.borland.com!not-for-mail