Jump to content

Recommended Posts

Posted

i opened a .txt file and run the script by clicking the background's autoit icon but the .txt file own't type?

don't i just need the code

Send("abcdedfg")?

and then alt tab to txt file?

  • Moderators
Posted

Send() will send to the window that has focus... look at ControlSetText() or ControSend().

Personally, if it's a .txt file, I just use FileWrite()/FileWriteLine() then open the file when everything is written to it.

Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.

Posted

Send() will send to the window that has focus... look at ControlSetText() or ControSend().

Personally, if it's a .txt file, I just use FileWrite()/FileWriteLine() then open the file when everything is written to it.

oh ok so u can open up the program using controlsettext too.. wow

thnx

can we make the program to shut down windows too? and restart it?

  • Moderators
Posted

oh ok so u can open up the program using controlsettext too.. wow

thnx

can we make the program to shut down windows too? and restart it?

1. No, I didn't say you could open a program with ControlSetText(), I said you could use ControlSetText() or ControlSend() in lieu of Send(). I also said you could use FileWrite()/FileWriteLine() to the .txt file, then use Run() to open the file right after, and you wouldn't have the concern of having to type it to an open window.

2. You'd be amazed at all the things you can do, as a matter of fact, there's this thing called the help file, that if you go to "index", and where it says "Type in the keyword to find:", if you typed Shut in there, poof, something pops up that may in fact help you.

Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...