I usually use textboxes, but I don't see why you couldn't use a picturebox (you will not be able to use a Label because the label control does not have an hWnd property.)
In the pictureboxs property page set the mouse pointer to 99-Custom
In the mouseicon property load the picture that you want to use. Then add this code to the mouseover eventPlace whatever code is necessary in the pictureboxes click event.VB Code:
Option Explicit Private Declare Function SetCapture Lib "User32" (ByVal hwnd As Long) As Long Private Declare Function ReleaseCapture Lib "User32" () As Long Private Declare Function GetCapture Lib "User32" () As Long Private Sub Picture1_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single) If (X < 0) Or (Y < 0) Or (X > Picture1.Width) Or (Y > Picture1.Height) Then ReleaseCapture ElseIf GetCapture() <> Picture1.hwnd Then SetCapture Picture1.hwnd End If End Sub




Reply With Quote