Hello everyone,
I am trying to Detect both mouse click and keyboard keydown event anywhere on screen, inside or outside project. Google helps me to find mouse clicks anywhere on screen, but I couldn't find any solution to detect keyboard clicks.
Anyone can help me to count keyboards clicks anywhere on screen
Thank you
Ladak
I am trying to Detect both mouse click and keyboard keydown event anywhere on screen, inside or outside project. Google helps me to find mouse clicks anywhere on screen, but I couldn't find any solution to detect keyboard clicks.
Code:
Private Sub FrmSelectTask_Load(sender As Object, e As EventArgs) Handles MyBase.Load
TimerMouseDetect.Start()
TimerMouseDetect.Interval = 100
End Sub
Code:
Private Sub TimerMouseDetect_Tick(sender As Object, e As EventArgs) Handles TimerMouseDetect.Tick
If MouseButtons = Windows.Forms.MouseButtons.Left Then
MouseClickCounts = MouseClickCounts + 1
End If
If MouseButtons = Windows.Forms.MouseButtons.Right Then
MouseClickCounts = MouseClickCounts + 1
End If
End Sub
Thank you
Ladak