When remotely accessing my home desktop with LogMeIn, a popup notification appears on the computer being remotely accessed. I wrote an AutoIt script to automatically close this little popup, but it doesn't work! When i call WinList() it returns the title ("LogMeIn") and handle of the popup just fine, but none of the usual AutoIt commands seem to work on it (WinKill, WinClose, etc). Any help would be greatly appreciated.
Here is my original script:
Opt("TrayIconHide", 1)
Opt("WinTitleMatchMode", -2)
$i = 0
Do
WinWait ("LogMeIn")
Winkill ("LogMeIn")
Until $i = 1
When the above didn't work, I tried a fancier script:
Opt("TrayIconHide", 1)
Opt("WinTitleMatchMode", -2)
$i = 0
Do
DoesLMIExist()
Until $i = 1
Func DoesLMIExist()
$var = WinList()
For $i = 1 to $var[0][0]
If $var[$i][0] = "LogMeIn" Then
;;;;; The msgbox below appears just fine
MsgBox(0, "Details", "Title=" & $var[$i][0] & @LF & "Handle=" & $var[$i][1])
;;;;; None of the below commands are successful in closing the popup
WinKill($var[$i][0])
WinKill($var[$i][1])
WinKill("LogMeIn")
WinClose($var[$i][1])
WinClose("LogMeIn")
EndIf
Next
EndFunc
The scripts work fine in Windows XP but not on Windows 7. Can anyone help?
Thanks!