Hello,
I want to change the mouse cursor like Hand Cursor (Normally we see this cursor in Web Link) when mouse moves on a label and change back to default when move to form.
Please help me
Farooq
Printable View
Hello,
I want to change the mouse cursor like Hand Cursor (Normally we see this cursor in Web Link) when mouse moves on a label and change back to default when move to form.
Please help me
Farooq
This example changes the color of a button, but should be good enough to be able to subtstitue what you want.
Thanks,
I dont want to change the color of button, i want to change the mouse Cursor
First set the label's MousePointer to 99 (custom). And then assingn the the MouseIcon property a cursor/icon file (which can be a 'Hand' as u want).Quote:
Originally Posted by hafizfarooq
Pradeep :)
Thanks
Please give me some to to do the above ?
Have a look at this : http://www.vbforums.com/showthread.php?t=234469
You said you wanted a different cursor when the mouse was over a label. The method is the same for coloring a button, except for one statemnt to color and another to uncolor. You need the same thing with a change to where it colors the control, to changing the cursor.Quote:
Originally Posted by hafizfarooq
Also, put the code from the buttone into coding for the label.
Thanks,
Problem RESOLVED with the follwoing code
Private Sub Form_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
Me.MousePointer = 0
End Sub
Private Sub Label1_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
Me.MousePointer = 99
Me.MouseIcon = LoadPicture("C:\Harrow.Cur")
End Sub
Thanks to all
Even know its resolved, doing a search for ".cur" will turn up hundreds. Good luck. :)Quote:
Thanks
Please give me some to to do the above ?
*EDIT* I meant search within your computer not google btw :)
You don't need that code to set the hand cursor for a label. The Label itself also have the MousePointer and MouseIcon properties which you can set at design time.