cursor show and hide

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

quick question, im making a a program and when the mouseposition gets to a
caertain point, it will be shown, if it isnt ther, it will be hidden. i have
the code written and set breakpoints but it wont work, heres what i have

if me.mouseposition.Y >= 100 then
me.cursor.hide
else
me.cursor.show
end if

but when it gets below 100, it doesnt show up even though, when i set a
breakpoint there, it executes the code....help
 
Try this:

Private Sub Form1_MouseMove(ByVal sender As Object, ByVal e As
System.Windows.Forms.MouseEventArgs) Handles MyBase.MouseMove
If Me.Cursor.Position.X >= 100 Then
Me.Cursor.Hide()
Else
Me.Cursor.Show()
End If
End Sub

I hope this helps

Crouchie1998
BA (HONS) MCP MCSE
 
hi, yea that didnt work, it does the same thing. when i set the breakpoint it
says that the Y coordinate is less that 100 and ti highlights the code
"me.cursor.show()" but it wont show it
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top