Home Desktop products Programming About us
XDESK SysTrayX XFilesDialog Downloads Translations Register FAQ
The system tray (also known as the "systray", "tray notification area" and more recently "taskbar notification area" or "status area") is that part of the Windows Taskbar that usually displays the time and a number of small icons from other "less visible" programs.
You can hide the clock from the system tray but normally there is very little or no control over the icons added there by different programs (which, as in the picture above, can reach an impressive number) - and that's where our program SysTrayX can be very handy! (even if in WinXP Microsoft has finally added a similar feature, it is still less usable than our program, and let's not speak about their strange idea of "inverting" the entire tray - fortunatelly in v3 SysTrayX will not only restore back the normal order but will also allow you to permanently sort the tray! ).
The main idea of the tray icons is that programs that are running all the time but do not need a full visible window should not take precious desktop space, but instead should only add an icon to the system tray, and should provide their functions from there - with a menu (which is usually activated with a right-click of the mouse over the tray icon), a minimal interface (after a left-click) or with the full user interface (normally activated after a left double-click) - the volume indicator (represented by the small speaker icon) is a good example for that (and probably the very first program that was using the system tray, back in Win95).
The icons from the system tray usually have a short name (which is normally displayed as a ToolTip when the mouse pointer is located over the corresponding icon in the tray) and in more recent versions of Windows it is also possible to have a special bigger "ballon ToolTip" which can provide more information (including a bold tile) and which can also be visible for a short time even of the mouse pointer is not over the tray (which can be a good way to display non-critical information or notifications).
All the normal functions that provide access to the system tray are based on a single API function called Shell_NotifyIcon (exported from SHELL32.DLL) and which is using a structure called NOTIFYICONDATA that contains all the information about the desired actions - the only problem might be that the structure can have 4 different versions and in order to write a program that will still work on older Windows versions you will have to decide at run-time which NOTIFYICONDATA is required!
The API also requires a window for notifications, and while that is a simple thing in C/C++ it might become a problem with certain RAD tools (like Visual Basic) - but usually you can find a control or library that implements a simpler interface or some other methods.