capsandiego Posted March 14, 2009 Posted March 14, 2009 Hi All, I have a very strange problem. If I run the simple PHP script on the server while I'm logged in via MSTSC (Desktop Remote) it works. But if I log out (always via MSTCS) and schedule the script to run, the Send() command fails and nothing is written to the Notepad page. I tried several times and it's related to the Send() command only. Does the MSTCS program lock AutoIt somehow? Is there something I have to configure on my XP server? Thanks in advance, best Regards. $autoIt = new COM('AutoItX3.Control'); $autoIt->Run('notepad.exe'); $autoIt->WinActivate("Untitled",""); $autoIt->Send("Hello World!","Untitled");
Developers Jos Posted March 14, 2009 Developers Posted March 14, 2009 There is no actual screen session to send keystrokes to when you schedule the script. Used ControlSend() as that should work. Jos SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past.
capsandiego Posted March 14, 2009 Author Posted March 14, 2009 There is no actual screen session to send keystrokes to when you schedule the script.Used ControlSend() as that should work.JosHi Jos, Thanks very much... this is something I didn't think of... and it has a big impact on the script... I need to replace all Send() with ControlSend() so I'm forced to specify the Control ID/NN for all the input fields I want to populate.... since there is no other way to do it I'll do...Thanks againRegardsSergio
capsandiego Posted March 15, 2009 Author Posted March 15, 2009 There is no actual screen session to send keystrokes to when you schedule the script.Used ControlSend() as that should work.JosHi Jos, the function WinWaitActive() is also affected by the schedule? It seems it doesn't work...Thanks in advance
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