Solved

How can I list all icons in systray?

Posted on 2004-04-25
9
391 Views
Last Modified: 2010-04-05
I'm trying to make myself a "slimer" shell...
My only problem is applications disappearing in what should be the systray.
They minimize to nowhere...
How can i list all apps using Tray Icons ?
0
Comment
Question by:The_SnifF
  • 5
  • 3
9 Comments
 
LVL 3

Expert Comment

by:smot
ID: 10912844
Hi,

With madKernel you can manage tray icons (see API "Shell_NotifyIcon") of any application.
This kind of functionality is totally undocumented, but works well from win95 to winXP

http://help.madshi.net/TrayIcons.htm 

Download:
http://madshi.bei.t-online.de/madCollection.exe


Example:

uses
  MadKernel;

      for i := 0 to TrayIcons.ItemCount -1 do
      begin
        ShowMessgage(TrayIcons[i].Window.OwnerProcess.ExeFile);
      end;
0
 

Author Comment

by:The_SnifF
ID: 10922878
thanks you so so soooooo much! :))
0
 

Author Comment

by:The_SnifF
ID: 10922895
Damn, ItemCount returns 0, and there are icons there... :S

BTW, can I get this collections source?
0
 
LVL 20

Expert Comment

by:Madshi
ID: 10922939
It works only if the tray window is visible, which is probably not the case if you're trying to write your own shell, right? There are some projects out there with full sources for replacing the Windows shell - including the tray icon stuff. I don't have any links (sorry), but a search in google might help.
0
Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

 

Author Comment

by:The_SnifF
ID: 10923404
If anyone could help me find links, i'd be grateful.
I searched google for days!
0
 
LVL 20

Accepted Solution

by:
Madshi earned 250 total points
ID: 10925717
0
 

Author Comment

by:The_SnifF
ID: 10926542
Thanks, though I found that page, the one with Delphi source isn't available.
And one VB source I couldn't get...
I'll try the others :)
0
 

Author Comment

by:The_SnifF
ID: 10969307
ok, i got it, my apps "says" it is the systray
that way:
  WM_TASKBARCREATED := RegisterWindowMessage('TaskbarCreated');
  PostMessage(HWND_BROADCAST, WM_TASKBARCREATED, 0, 0);
0
 
LVL 20

Expert Comment

by:Madshi
ID: 11140950
Yes, and I guess you have to create your own window with the correct class name which claims to be the systray.
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

A lot of questions regard threads in Delphi.   One of the more specific questions is how to show progress of the thread.   Updating a progressbar from inside a thread is a mistake. A solution to this would be to send a synchronized message to the…
The uses clause is one of those things that just tends to grow and grow. Most of the time this is in the main form, as it's from this form that all others are called. If you have a big application (including many forms), the uses clause in the in…
Windows 10 is mostly good. However the one thing that annoys me is how many clicks you have to do to dial a VPN connection. You have to go to settings from the start menu, (2 clicks), Network and Internet (1 click), Click VPN (another click) then fi…
Both in life and business – not all partnerships are created equal. As the demand for cloud services increases, so do the number of self-proclaimed cloud partners. Asking the right questions up front in the partnership, will enable both parties …

920 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

14 Experts available now in Live!

Get 1:1 Help Now