VB Code:
Option Explicit
Private Declare Function SetCapture Lib "user32" (ByVal hwnd As Long) As Long
Private Declare Function GetCapture Lib "user32" () As Long
Private Declare Function ReleaseCapture Lib "user32" () As Long
Private Sub Text1_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
With Text1
If ((X < 0) Or (X > .Width) Or (Y < 0) Or (Y > .Height)) Then 'MouseOut
Call ReleaseCapture
Label1.Caption = "Mouse Out!"
ElseIf GetCapture <> .hwnd Then 'MouseEnter
Call SetCapture(.hwnd)
Label1.Caption = "Mouse Enter!"
Else
'Mouse Move
End If
End With
End Sub