🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.cppbuilder.nativeapi
Article #6494

Re: Displaying Baloon tips in the taskbar

#6494
From: Danila Vershinin
Date: Wed, 04 May 2005 14:20
32 lines
2387 bytes
Ok, with a TTrayIcon component dropped on the form I use the following piece 
of your code for a test: (this code I've put in the OnClick event handler of 
trayicon to be sure now that it is in the taskbar now)

NOTIFYICONDATA IconData;
            IconData.cbSize = sizeof( NOTIFYICONDATA );
            IconData.uID    = 0;     //<---- what should be here?
            IconData.hWnd   = Handle;
            IconData.uFlags = NIF_MESSAGE|NIF_ICON|NIF_TIP;
            //IconData.uCallbackMessage = WM_TRAYNOTIFY;  //-<--- callback 
message, commented cuz I don't have one
            lstrcpy( IconData.szTip,
             "This is a test" );
            IconData.hIcon  = TrayIcon->Handle; // <<<--- by the way what is 
the difference between TrayIcon->Handle and TrayIcon->GetHandle()? code 
completeion says that TrayIcon->Handle is of boolean type
IconData.dwInfoFlags = NIIF_INFO;
            //IconData.dwInfoFlags = NIF_TIP;

            IconData.uFlags = NIF_INFO;
            IconData.uTimeout = 15000;
            StrLCopy( IconData.szInfo, "Test string", 255 );
            StrLCopy( IconData.szInfoTitle, "Test string 2", 63 );
            Shell_NotifyIcon( NIM_MODIFY, &IconData );

correct me what I am doing wrong. clicking on the tray icon doesn't bring 
the balloon tip on.


"Vladimir Stefanovic" <antivari@po.sbb.co.yu> wrote in message 
news:4278b6a6@newsgroups.borland.com...
<. You have to remove some parts, to adjust your needs:
Technical Details
Message-ID: <4278dac5@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!g2news1.google.com!news4.google.com!news3.google.com!news.glorb.com!newsfeeds.ihug.co.nz!ihug.co.nz!newsgroups.borland.com!not-for-mail
References: <42762d6f@newsgroups.borland.com> <4278b6a6@newsgroups.borland.com>

Show Full Headers
Complete Article Headers
X-Google-Thread: 10cc67,592a743b28e0761c
X-Google-Attributes: gid10cc67,public
X-Google-Language: ENGLISH,ASCII-7-bit
From: "Danila Vershinin" <danprep@yahoo.com>
Newsgroups: borland.public.cppbuilder.nativeapi
References: <42762d6f@newsgroups.borland.com> <4278b6a6@newsgroups.borland.com>
Subject: Re: Displaying Baloon tips in the taskbar
Date: Wed, 4 May 2005 18:20:13 +0400
Lines: 34
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2900.2527
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2527
X-RFC2646: Format=Flowed; Response
NNTP-Posting-Host: 62.33.222.122
Message-ID: <4278dac5@newsgroups.borland.com>
X-Trace: newsgroups.borland.com 1115216581 62.33.222.122 (4 May 2005 07:23:01 -0700)
Path: arc1-ca.pugleaf.net!g2news1.google.com!news4.google.com!news3.google.com!news.glorb.com!newsfeeds.ihug.co.nz!ihug.co.nz!newsgroups.borland.com!not-for-mail