Click here to Skip to main content
15,890,282 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hello, I am wondering how can I show a balloon tip for my system tray NotifyIcon application QUICKLY. What I mean by quickly is not linger around for like 5 seconds.. I have tried entering 1. For example my code is currently:
NotifyIcon1.ShowBalloonTip(10)
I thought about trying decimals but if I remember correctly from C++ it does nto work or make a difference.. So could someone please tell me how to display a balloon tip that pops up for only 1 second then dissapears very fast?
Thank you! :)
Posted

See http://msdn.microsoft.com/en-us/library/ms160064.aspx[^].
As per this link "Minimum and maximum timeout values are enforced by the operating system and are typically 10 and 30 seconds, respectively, however this can vary depending on the operating system. Timeout values that are too large or too small are adjusted to the appropriate minimum or maximum value. In addition, if the user does not appear to be using the computer (no keyboard or mouse events are occurring) then the system does not count this time towards the timeout.".
So unfortunately, it looks like you can't do too much with the timeout parameter in this method.
 
Share this answer
 
Comments
NY Andrew 26-May-11 13:45pm    
Thanks.. Not sure where to go from here..
No you cannot. The minimum and maximum timeout values are enforced by the operating system and is typically 10 and 30 seconds. But I think it can be changed via Registry settings. But then it will be global for all programs that uses BalloonTip.

I think a better option is to make the BalloonTip your self, then you can make it as fast as you like.
But speed is not good her. The end user will not enough time to see the BalloonTip.

And if the use is not using the computer, he or she will never see the message. NotifyIcon.ShowBalloonTip has some logic built-in about all that.
 
Share this answer
 
Comments
NY Andrew 26-May-11 13:47pm    
That might be a good idea.. Change the registry value when my application is running and then when it stops put the default value back! Any idea where that key is located by the way?
Yes very tru.. Any tips how to create my own custom balloon tip notification? I didn't even know that was possible.
Kim Togo 27-May-11 11:01am    
See http://msdn.microsoft.com/en-us/library/bb773352(v=vs.85).aspx
And under "uTimeout" parameter. I do not think it is easy to change systemwide timeout for balloon tips. And if you manage to change them in registry, I think it requires a reboot or logoff and logon of the user.

The best option, is to create your own balloon tip form, that can be showed.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900