Add two labels (Label1 , Label2) and a timer (Timer1).
VB Code:
Option Explicit Private Type POINTAPI 'Declare types x As Long y As Long End Type Private Declare Function GetCursorPos Lib "user32" _ (lpPoint As POINTAPI) As Long 'Declare API Dim z As POINTAPI 'Declare variable Private Sub Form_Load() Timer1.Interval = 1 Timer1.Enabled = True End Sub Private Sub Timer1_Timer() GetCursorPos z 'Get Co-ordinets Label1 = "x: " & z.x 'Get x co-ordinets Label2 = "y: " & z.y 'Get y co-ordinets End Sub