adminmorin Posted November 21, 2011 Share Posted November 21, 2011 I have used autoit for years and have searched for this specific problem to no avail. I have a 2003 server where run a script as a scheduled task. This script launches a software application and sends keystrokes to the window (I use ControlSend as well as well as ControlFocus...to focus on the window. I do not use WinWaitActive) The script does run when logged off but I am sure that it is having issues sending the keystrokes to the window of the program being launched. In a later part of the script I have it look for a windw and if it is not there then it it exits and sends me an email. I get the unsuccessful email so I know the script has launched when logged off. Any help help would be greatly appreciated.Here is a portion of the script. run ("y:\dmwin.exe","y:")sleep (4000)WinWait ("[CLASS:xSchoolmaster5500wialog0]","",10)sleep (1000)ControlFocus("[CLASS:xSchoolmaster5500wialog0]","","xSchoolmaster5500child01")ControlSend("[CLASS:xSchoolmaster5500wialog0]","","xSchoolmaster5500child01","district")sleep (2000) Link to comment Share on other sites More sharing options...
Zedna Posted December 15, 2011 Share Posted December 15, 2011 Look herehttp://www.autoitscript.com/wiki/FAQ#Why_doesn.27t_my_script_work_on_a_locked_workstation.3FTry ControlSetText() instead of ControlSend() if possible. 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