lsakizada Posted May 4, 2008 Share Posted May 4, 2008 I have an au3 program that need to be restarted frequently.After the application restarted the ControlClick is issuing the click command on a button.The problem is that when the desktop is locked then the ControlClick does not working.I have tried the code bellow, but the ControlClick is still not sending the click command.What to do?If IniRead(@ScriptDir & "\" & "config.ini", "SET", "isLaunch", "0") = 1 Then If Not WinActive($AppName, "") Then WinActivate($AppName, "") WinWaitActive($AppName, "") ControlFocus ( "", "", $Monitor ) ControlClick("", "", $Monitor) EndIfBTW: It is possible to detect that the desktop is locked but i do not know how to benefit from that.here is the link to Gary Frost code of detecting locked computer. Be Green Now or Never (BGNN)! Link to comment Share on other sites More sharing options...
Zedna Posted May 4, 2008 Share Posted May 4, 2008 Look here Resources UDF ResourcesEx UDF AutoIt Forum Search Link to comment Share on other sites More sharing options...
lsakizada Posted May 4, 2008 Author Share Posted May 4, 2008 (edited) Look hereI am not quiet understood the solution.can you please clarify? Edited May 4, 2008 by lsakizada Be Green Now or Never (BGNN)! Link to comment Share on other sites More sharing options...
Zedna Posted May 4, 2008 Share Posted May 4, 2008 Try: If IniRead(@ScriptDir & "\" & "config.ini", "SET", "isLaunch", "0") = 1 Then ControlFocus ( $AppName, "", $Monitor ) ControlClick($AppName, "", $Monitor) EndIf Resources UDF ResourcesEx UDF AutoIt Forum Search Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now