1

Let's say I have a cursor named myCur.cur. What I would like to do is use that cursor on my desktop application instead of the boring cursor provided by Visual Studio 2005. How do I write for that?

Rabin
  • 1,563
  • 4
  • 20
  • 44

1 Answers1

2

If you're targeting WinForms, load a cursor file (the one with the ".cur" extension) that you created

Cursor myCursor = new Cursor("myCursor.cur");

then assign it as the cursor on any of your controls:

myControl.Cursor = myCursor;

For additional information on how to do more than this, and create your cursor programmatically instead of loading it from a file, then check out this tutorial.

Should you be or become interested in how to do this in WPF, there's also an article to this regard.

luvieere
  • 37,065
  • 18
  • 127
  • 179