trids 2 Posted March 20, 2004 Share Posted March 20, 2004 The ToolTip and TrayTip functions are really cool .. but does anyone have any idea how to set the tooltip of a tray icon? I'm talking about the tooltip that appears when you hover over the Autoit icon in the system tray. When you run a compiled script, the tooltip reflects the name of the EXE. So I thought I would try things like WinSetTitle on it, but ... .See, I have a script that I launch multiple times: each time with a different INI file, and I'd like append the name of the INI file to the tooltip of the tray icon that is processing it, so that I can tell them apart. Eg: MyScript.exe - group1.ini, and MyScript.exe - group2.ini .. etcI can do workarounds like periodically running a TrayTip call .. but that's messy in so many ways; and I have a feeling I'm missing something really obvious - any ideas? TIA Link to post Share on other sites
Valik 481 Posted March 20, 2004 Share Posted March 20, 2004 The tooltip is just a window which has the title of whatever text it will display. It should be possible to get the handle to it (May have to search child windows, too). Once you have the handle, yout should be able to change the title to change the text. This is all theoretical, I've never tested. Link to post Share on other sites
Valik 481 Posted March 20, 2004 Share Posted March 20, 2004 Ehhh, maybe not, I don't see the window in Spy++ anywhere. Link to post Share on other sites
Developers Jos 2,852 Posted March 20, 2004 Developers Share Posted March 20, 2004 The systemtray icon is set with the Shell_NotifyIcon call to Lib "shell32". nic.cbSize= sizeof(NOTIFYICONDATA); nic.hWnd= hWnd; nic.uID= AUT_NOTIFY_ICON_ID; nic.uFlags= NIF_ICON | NIF_MESSAGE; nic.uCallbackMessage = AUT_WM_NOTIFYICON; nic.hIcon= LoadIcon(g_hInstance, MAKEINTRESOURCE(IDI_MAIN_32x32x16)); Shell_NotifyIcon(NIM_ADD, &nic); SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past. Link to post Share on other sites
trids 2 Posted March 20, 2004 Author Share Posted March 20, 2004 Thanks for the quick reply, folks .. I'm almost glad to see I didn't miss anything The systemtray icon is set with the Shell_NotifyIcon call to Lib "shell32".So does this mean a new built-in intrinsic function? .. Link to post Share on other sites
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now