Search code examples
c#.netwinforms.net-4.0mousehover

Changing the time it takes for the mousehover event to fire


I'm making a winforms C# project with .NET 4.

I want to display a tooltip when the mouse hovers over a button or a textbox or whatever. Right now it displays almost as soon as the mouse stops moving. I don't like this. I want it to have more of a delay.

Is there any way I can set a mousehover event delay time that is the same for all installed users?

I suppose I could start a timer, and then cancel the timer when the mouse moves again but there's got to be a better way by golly!


Solution

  • Try this I think it will really help You

     ToolTip t = new ToolTip();
     t.InitialDelay = 500;
     t.SetToolTip(button1, "Hello");