tags:

views:

31

answers:

1

I've created notifyIcon object. But after I click button1 balloon seems to be shown infinitely, despite the fact that I've specified 1 millisecond (!!!) as interval.

    private void button1_Click(object sender, EventArgs e)
    {
        notifyIcon1.ShowBalloonTip(1);
    }

What have I done wrong?

UPD: i've found this: http://www.csharp411.com/notifyiconshowballoontip-issues/ Seems like it is expected balloon behaviour :-S

+1  A: 

Quote from the MSDN article:

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.

Hans Passant
I'm amazed why did not they validate the period to be >= 10000 then? They do for negative values, but don't for another **meaningless** values :-S
zerkms
*however this can vary depending on the operating system*
Hans Passant