W2k script. command based program needs menu input.
Posted on 2004-04-28
I have a program that checks some application things which can be run manually from
a command prompt.
What i want to do is to script it in a batch file ( w2k ) but the program
needs to have input to get to the correct screen inside the program.
Example if run it manually........
c:\> test.exe ( after i press enter i get to a menu )
The next steps in the program would be choosing menu item " m "
which shows another screen with info that i want want to pipe to a log file. So i would like it
to look something like this
c:\>test > test.log
It would automatically run the program, enter the menu selection " m ", show info on that screen and then choose " q " for quit.
So how can i enter the inputs that is needed in the script automatically ? The program
is just a ascii menu driven program, dos program. No graphics so the info that comes on the screen should be fine in a log file.