Home All Groups Group Topic Archive Search About

I'd like to get an event each time the cursor stops moving.

Author
29 Mar 2005 10:14 PM
Just Me
If I move the mouse cursor over a control and stop moving I get a MouseHover
event.

If I then move the cursor while staying within the control and then stop
moving I do not get another MouseHover event.

To get a Mousehover I must leave and reenter the control.

I'd like to get an event each time the cursor stops moving.

Anyone know how to do that?


Thanks

Author
29 Mar 2005 11:03 PM
Bob Powell [MVP]
Every time the mouse moves RESET a timer wit a timeout of n milliseconds.
When the mouse stops moving the timer will stop being reset and will
eventually expire.

--
Bob Powell [MVP]
Visual C#, System.Drawing

Find great Windows Forms articles in Windows Forms Tips and Tricks
http://www.bobpowell.net/tipstricks.htm

Answer those GDI+ questions with the GDI+ FAQ
http://www.bobpowell.net/faqmain.htm

All new articles provide code in C# and VB.NET.
Subscribe to the RSS feeds provided and never miss a new article.





Show quoteHide quote
" Just Me" <gro***@a-znet.com> wrote in message
news:Ow$g%23yKNFHA.3328@TK2MSFTNGP14.phx.gbl...
> If I move the mouse cursor over a control and stop moving I get a
> MouseHover event.
>
> If I then move the cursor while staying within the control and then stop
> moving I do not get another MouseHover event.
>
> To get a Mousehover I must leave and reenter the control.
>
> I'd like to get an event each time the cursor stops moving.
>
> Anyone know how to do that?
>
>
> Thanks
>
Author
29 Mar 2005 11:18 PM
Grant_Aust
That's tricky Bob !
Author
29 Mar 2005 11:26 PM
Just Me
Thanks. I had thought of that but before I did anything like that I like to
know from an expert like you that I'm not missing some simpler approach.

Thanks a lot.

PS

Speaking of a better approach your previous suggestion concerning
StringFormat opened new vistas.
Your site was great too!


Show quoteHide quote
"Bob Powell [MVP]" <bob@_spamkiller_bobpowell.net> wrote in message
news:eTHDVNLNFHA.1732@TK2MSFTNGP14.phx.gbl...
> Every time the mouse moves RESET a timer wit a timeout of n milliseconds.
> When the mouse stops moving the timer will stop being reset and will
> eventually expire.
>
> --
> Bob Powell [MVP]
> Visual C#, System.Drawing
>
> Find great Windows Forms articles in Windows Forms Tips and Tricks
> http://www.bobpowell.net/tipstricks.htm
>
> Answer those GDI+ questions with the GDI+ FAQ
> http://www.bobpowell.net/faqmain.htm
>
> All new articles provide code in C# and VB.NET.
> Subscribe to the RSS feeds provided and never miss a new article.
>
>
>
>
>
> " Just Me" <gro***@a-znet.com> wrote in message
> news:Ow$g%23yKNFHA.3328@TK2MSFTNGP14.phx.gbl...
>> If I move the mouse cursor over a control and stop moving I get a
>> MouseHover event.
>>
>> If I then move the cursor while staying within the control and then stop
>> moving I do not get another MouseHover event.
>>
>> To get a Mousehover I must leave and reenter the control.
>>
>> I'd like to get an event each time the cursor stops moving.
>>
>> Anyone know how to do that?
>>
>>
>> Thanks
>>
>
>