2 answers
The Shell_NotifyIcon function adds, deletes and changes the icon. NOTIFYICONDATA - structure for storing an icon.
- There on the link
Shell_NotifyIcon
there is an example. - Ildar
|
Use the CoolTrayIcon component (or TJvTrayIcon).
- Download component.
- Add it to the form.
- In the properties you set an icon.
- In the properties set the value of IconVisible to true.
To hide the program in tray:
CoolTrayIconX.HideMainForm;
To show the program from the tray:
CoolTrayIconX.ShowMainForm;
If you do not want a component, you can do everything yourself using the Windows API function Shell_NotifyIcon.
- Thank. The first is optimal for Delph, the second is for all cases. - Oleg53
|