Detect clicks / cords while mouse input is being blocked: Here is a solution I came up with. I am still new to AutoIT, so it may be a little crude. Using the UDF from this post and the UDF from LxP's post of "_ControlGetHandleByPos" here. #include <_ControlGetHandleByPos.au3>
#include <MouseSetOnEvent_UDF.au3>
AutoItSetOption("TrayIconDebug", 1)
HotKeySet("{PAUSE}", "Terminate")
$winSiS = "LabCorp SIS"
_MouseSetOnEvent($MOUSE_PRIMARYDOWN_EVENT, "LeftMouseDown");Set LeftMouseClick Event
Dim $pos[2]
$pos[0] = 0
$pos[1] = 0
$intMC = 0
$ctrlInfo = "Not found or Exit before found."
While 1
Sleep(100)
If $intMC = 1 Then
$intMC = 0
_MouseSetOnEvent($MOUSE_PRIMARYDOWN_EVENT, "LeftMouseDown");Re-enable LeftMouseClick Event
EndIf
WEnd
Func LeftMouseDown()
_MouseSetOnEvent($MOUSE_PRIMARYDOWN_EVENT);Enable mouse button back.
MouseClick("left");Left Click were mouse is at to get data
$pos = MouseGetPos()
$ctrlHndl = _ControlGetHandleByPos($winSiS, "", $pos[0], $pos[1])
$curData = ControlGetText($winSiS, "", $ctrlHndl)
If StringLen($curData) > 12 Then $curData = StringLeft($curData, 12)
$handle = ControlGetHandle($winSiS, "", $ctrlHndl)
$intMC = 1
$ctrlInfo = "Control Handle: " & $handle & " Data: " & $curData
ToolTip($ctrlInfo)
EndFunc
Func Terminate()
MsgBox(0, "Control Info", $ctrlInfo)
;ClipPut('MouseClick("left",' & $pos[0] & ',' & $pos[1] & ',1,1); wrt Client')
Exit
EndFunc ;==>Terminate