Knightsman Posted November 23, 2010 Posted November 23, 2010 Thanks in advance. I just installed AutoIT and was going through the tutorials. I'm stuck on the "Simple Notepad Automation". I have Vista Business SP2. I cannot for the life of me get it to close and save the note pad. The screen comes up do you want to save, and the script just stops, but stays running in the processes. This is the code, and Its exactly the same as the tutorial, but the alt does not work. Please help! Thanks again. Run("notepad.exe") WinWaitActive("Untitled - Notepad") Send("This is some text.") WinClose("Untitled - Notepad") WinWaitActive("Notepad", "Do you want to save") Send("!n")
somdcomputerguy Posted November 23, 2010 Posted November 23, 2010 Change WinWaitActive("Notepad", "Do you want to save") to WinWaitActive("Notepad").The text part ('Do you want to save') is what's holding up the script, not the send part. - Bruce /*somdcomputerguy */ If you change the way you look at things, the things you look at change.
Knightsman Posted November 23, 2010 Author Posted November 23, 2010 Awesome! That worked. What was the tutorial talking about? Did I miss something when it said to add it? Thanks a bunch, now I can keep learning
somdcomputerguy Posted November 23, 2010 Posted November 23, 2010 The example codes in the Help file were written before Microsoft changed the 'text' part that is now displayed. - Bruce /*somdcomputerguy */ If you change the way you look at things, the things you look at change.
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