🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

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

Refresh The System Tray

#4874
From: AJ
Date: Mon, 21 Nov 2005 17:21
17 lines
2010 bytes
I have created an application to end a specific program at a specific time 
each day. The application I am ending is not mine and I cannot modify it. 
When it starts, it is minimized to the system tray.  When my application 
ends it, the icon is still in the system tray until the mouse pointer is 
pointed on the system tray.  I have tried to investigate the 
Shell_NotifyIcon function, but since the application is not mine, I do not 
know the taskbar ID of the application.  This looks to be a required piece 
of information for the
function.  Is there any other way to do a general refresh of the system tray 
(similar to what happens when the mouse pointer is on the system tray) 
programatically?  In searching the web, Visual C++ has a utility call Spy++ 
that can imspect the icons in the system tray and return the taksbar ID. 
Then the Shell_NotifyIcon function can be used.  Does C++ Builder have any 
utility like this or does anyone know of a good way to do what I am trying 
to do?  Any help is appreciated.

AJ
Technical Details
Message-ID: <438201d2@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!g2news1.google.com!news4.google.com!border1.nntp.dca.giganews.com!nntp.giganews.com!feed5.newsreader.com!newsreader.com!news-out.newsgroups.com!propagator2-sterling.newsfeeds.com!in.nntp.be!caladan.landsraad.net!newsgroups.borland.com!not-for-mail

Show Full Headers
Complete Article Headers
X-Google-Thread: 10cc67,8ad97936ff76c516,start
X-Google-Attributes: gid10cc67,public
X-Google-Language: ENGLISH,ASCII-7-bit
Reply-To: "AJ" <adam_bouchard@sbcglobal.net>
From: "AJ" <adam_bouchard@sbcglobal.net>
Newsgroups: borland.public.cppbuilder.nativeapi
Subject: Refresh The System Tray
Date: Mon, 21 Nov 2005 11:21:21 -0600
Lines: 20
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2900.2180
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2180
X-RFC2646: Format=Flowed; Original
NNTP-Posting-Host: 70.250.210.228
Message-ID: <438201d2@newsgroups.borland.com>
X-Trace: newsgroups.borland.com 1132593618 70.250.210.228 (21 Nov 2005 09:20:18 -0700)
Path: arc1-ca.pugleaf.net!g2news1.google.com!news4.google.com!border1.nntp.dca.giganews.com!nntp.giganews.com!feed5.newsreader.com!newsreader.com!news-out.newsgroups.com!propagator2-sterling.newsfeeds.com!in.nntp.be!caladan.landsraad.net!newsgroups.borland.com!not-for-mail