10-06-2010 03:24 AM
the answer is in the title
I want to create a tooltips on my application icon tray, in the status bar icon.
I think that the solution is in the SDK, but i dont know to implement this code:
source MSDN:
"
#define ARRAYSIZE(a) (sizeof(a)/sizeof(a[0]))
NOTIFYICONDATA IconData = {0};
IconData.cbSize = sizeof(IconData);
IconData.hWnd = hwndNI;
IconData.uFlags = NIF_INFO;
HRESULT hr = StringCchCopy(IconData.szInfo, ARRAYSIZE(IconData.szInfo), TEXT("Your message text goes here."));
if(FAILED(hr))
{
// TODO: Write an error handler in case the call to StringCchCopy fails.
}
IconData.uTimeout = 15000; // in milliseconds
Shell_NotifyIcon(NIM_MODIFY, &IconData);
"
01-05-2011 10:02 AM
If you're interested in the icons in the notification area, I think the easiest solution is to use the "System Tray Icons" functions in toolbox.fp.
You can create a new icon calling InstallSysTrayIcon(), and you can also set the tooltip text.