Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Can you recommend software that records what you are doing and then plays back the commands as well as allowing you to save that recording and set it up as an automatic task?

The reason I ask is because I'm struggling with automating a manual task because I don't have a way to pass the inputs to it via a normal vbscript or similar. The command is started from a command line but then asks for different inputs (that remain constant on each run).

I'd like a way to record it once, telling it to run "program.exe" then telling it to type "2" and "enter" and then "Bob" and "enter", etc.

Is my best bet AutoIT? I saw it in another question but haven't looked deeply at it in case someone else here had another suggestion that would be better.


P.S. I'm aware that this should be a last resort type thing, but I'm tired of running the same thing daily manually.

share|improve this question
I've found a sledgehammer and knobbling post to work quite well. At the very least, it discourages the developer from writing any more programs that can't be automated. – womble Jul 19 '12 at 13:41
@womble - While I agree with's a 3rd party app and I can't call the company and tell them to rewrite it with my personal input parameters, recompile, and send to me. I take that back, I could, but without enough cash they aren't likely to do it. – TheCleaner Jul 19 '12 at 13:50
up vote 6 down vote accepted

I have used AutoIT successfully years ago for such a task. It's certainly the most "prominent" of programs, I think.

share|improve this answer
And you can compile AutoIt scripts into a standalone executable and this executable can be used without the need for AutoIt to be installed on the machine. – Kalatzis Stefanos Jul 19 '12 at 13:44

If the window title is consistent you can probably get by with a quick-and-dirty VBScript program using the WScript.Shell SendKeys method. Here's a simple script that illustrates the point:

Set objShell = WScript.CreateObject("WScript.Shell")

objShell.Run "calc.exe"

Do Until Success = True
    Success = objShell.AppActivate("Calculator")
    Wscript.Sleep 1000

objShell.SendKeys "94011/3="

This is a very brittle method of automation but extremely inexpensive. It works fairly well if it's running in an environment where no interactive user will be messing with the machine while the script is running.

Microsoft has some reference about how to send "special keys" on their site.

share|improve this answer
Evan, thanks, I'll test that route as well. Would I need to set some pauses/sleeps between SendKeys? Meaning if I have one input that then created output, would the next SendKeys wait for that output or immediately try to send something? – TheCleaner Jul 19 '12 at 18:17

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.