How can I change the mouse's pointer

  • Thread starter Thread starter Christian Blackburn
  • Start date Start date
C

Christian Blackburn

Hi Gang,
In VB6 is was relatively easy to change the pointer, but now I don't even
see that as a property for any objects. Can somebody tell me how to do that
in .NET?
Thanks in Advance,
Christian Blackburn
 
Christian Blackburn said:

Hi guy,
In VB6 is was relatively easy to change the pointer, but now I don't
even see that as a property for any objects. Can somebody tell me
how to do that in .NET?

To change the cursor of a control:

Me.Cursor = Cursors.WaitCursor


To change the cursor for the application:

Cursor.Current = Cursors.WaitCursor

Cursor.Current is a shared member of the cursor class, not a property of the
Form's cursor.

The latter will keep the cursor only until Application.Doevents ist called
(see docs).
 
Hi Christian,

What search keywords did you use when you looked this one up in the Help
or on MSDN?

Regards,
Fergus
MVP [Windows Keyboard, PC Power Switch]
 
Hi Cor,
Are you referring to how late it is at night? Yes I am and yes it is 4:25AM
Pacifc Standard Time. Ahhh!
Adios Amigo,
Christian
 
Hello,

Christian Blackburn said:
In VB6 is was relatively easy to change the pointer, but now
I don't even see that as a property for any objects. Can
somebody tell me how to do that in .NET?

Use the 'Cursor' property instead.
 
see also:
http://msdn.microsoft.com/library/d...lBasic70ForVisualBasicVeterans.asp?frame=true


Visual Studio.NET
Visual Basic and Visual C#
Upgrading applications
Upgrading from VB 6.0
-> Introduction in VB.Net for experienced VB users

direct link:
ms-help://MS.VSCC.2003/MS.MSDNQTR.2003FEB/vbcon/html/vboriIntroductionToVisu
alBasic70ForVisualBasicVeterans.htm

(see hints in signature)


--
Armin

- Links might be split into two lines. Concatenate them using notepad.
- Links might require to add a ".nnnn" after the "2003FEB", e.g.
"2003FEB.1033" for localized versions.
- Links starting with "ms-help" are URLs for the document explorer (<F1>).
Paste them in the URL textbox and press enter. Using internal help (menu
tools -> options -> environment -> help), display the "Web" toolbar that
contains the textbox.
- The tree representing the table of contents has been translated from
localized (German) version. Excuse slight deviations.
 
Thanks guys,
Now that I've got the custom cursor it looks a bit more professional since
it's a board game and I'm using the hand pointer.
Cheers,
Christian Blackburn
 
Hi Armin,
Thanks Armin that is an excellent link I'll have to spend a week and
memorize all of it :). No sarcasm intended.
Cheers,
Christian
 
Back
Top