[Tim Golden] | > [Barnaby Scott] | > | > | So I'm thinking along these lines: | > | | > | import subprocess | > | sp = subprocess.Popen(r'C:\WINNT\SYSTEM32\runas.exe | > | /user:administrator | > | C:\Program Files\Microsoft Games\Age of Mythology\aom.exe') | > | #some sort of code to send the password here... | > | #help! | > | > I *think* -- and I'm happy to be wrong -- that there's | > no way you're going to get that password in there. One | > place to start looking might be: | > | > pywinauto - http://pywinauto.pbwiki.com/ | > | > which lets you automate Windows in general; don't know | > how much use it'll be here.
[Barnaby Scott] | Thanks for your tips. In fact the first link you gave put me onto | Sendkeys (http://www.rutherfurd.net/python/sendkeys/), which is a | prerequisite for pywinauto. In the end that was all I needed. In case | anyone else is interested here is my code now (with SendKeys | installed): Excellent! I'm glad it turned out to be so easy, and thanks for posting the code and the link. TJG ________________________________________________________________________ This e-mail has been scanned for all viruses by Star. The service is powered by MessageLabs. For more information on a proactive anti-virus service working around the clock, around the globe, visit: http://www.star.net.uk ________________________________________________________________________ _______________________________________________ Tutor maillist - Tutor@python.org http://mail.python.org/mailman/listinfo/tutor