Changing the Mouse Pointer to Hand just like on Hyperlinks

S

sameerce

Hi,
I wanted an image object to be placed on an Excel Sheet and when the
user brings the mouse over it, the mouse pointer should look like the
Hand object which we usually see on hyperlinks. Is there any way to do
this.

Thanks,
Sameer
 
P

papou

Hi sameer
This is possible when inserting an image from the controls tool bar and
setting MousePointer property to "fmMousePointerCustom" and then choosing
your icon in the MouseIcon property.
HTH
Cordially
Pascal
 
S

sameerce

Hi Pascal,
Thanks for the reply. But, the problem is that I could not find th
icon of the hand shape. Can any one tell me where I can find it in th
windows directory or if any one has it, please send it over a
attachment.

Thank You
Samee
 
J

Jamie Collins

sameerce wrote ...
Thanks for the reply. But, the problem is that I could not find the
icon of the hand shape. Can any one tell me where I can find it

The API:

Private Const IDC_HAND As Long = 32649&

Private Declare Function LoadCursor _
Lib "USER32" Alias "LoadCursorA" _
(ByVal hInstance As Long, _
ByVal lpCursorName As Long) As Long

Private Declare Function SetCursor _
Lib "USER32" (ByVal hCursor As Long) _
As Long

Private Sub Image1_MouseMove( _
ByVal Button As Integer, _
ByVal Shift As Integer, _
ByVal X As Single, _
ByVal Y As Single)
SetCursor LoadCursor(0, IDC_HAND)
End Sub

Jamie.

--
 
Top