Hide\Show Mouse Cursor

'Add a module to your project (In the menu choose Project -> Add Module, Then click Open)
'Insert 1 CommandButton to your form (named Command1).
'When you will press the button the mouse corsor will disappear.
'when you will quit the program by pressing Alt & F4, the mouse
'cursor will Appear Again.
'Insert this code to the module :

Declare Function ShowCursor& Lib "user32" (ByVal bShow As Long)

'Insert the following code to your form:

Private Sub Command1_Click()
ShowCursor& 0
End Sub

Private Sub Form_Unload(Cancel As Integer)
ShowCursor& 1
End Sub

Go Back