Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How do I set my mouse cursor to the hybrid hourglass and arrow in code? (.NET)

I have a timely operation that runs on a background thread. While running, I currently put the cursor in a wait state:

Mouse.OverrideCursor = Cursors.Wait

I just implemented a feature that allows the user to click a "Cancel" button if they're tired of waiting. However, some users may not realize they can do this (despite the cancel button being the only active control during the process) because they mouse cursor is an hourglass.

I've seen programs use a cursor that shows the hourglass and has an arrow pointer attached as well. How to I set the mouse cursor to this state? I looked through the .NET documentation and could not find this cursor.

Thanks!

like image 859
Rob Sobers Avatar asked Nov 10 '08 14:11

Rob Sobers


1 Answers

Me.Cursor = Cursors.AppStarting
like image 141
Martin Avatar answered Nov 04 '22 16:11

Martin