Jump to content

Simulated keystroke in DOS


bullet

Recommended Posts

I am trying to find a command that simulates pressing the "Enter" key. I have a network floppy disk that copies Win98 cabs from a network machine back to the local machine. Reboots and then starts setup.exe. Once setup starts I have to press the "Enter" key for it to continue. Not good for unattend. That is why I am looking for a command that I can insert that will do that for me. Anyone know the answer? Thanks :unsure:

Link to comment
Share on other sites


try this, create a text file containing only a carriage return, name it 'ENTER.TXT'

On the line where you run 'SETUP.EXE' change it to

SETUP.EXE <ENTER.TXT

This should work, but some programs will not take redirected text this way.

Link to comment
Share on other sites

  • 7 months later...

You could maybe make a batch file which executes it:

If you make a .bat file and call it 1.bat

and then inside it, type

Setup.exe

from here you could get you floppy to start the program, not the best idea, but maybe it will work, you also add other commands like

Setup.exe /id /is /iw :this would skip the scandisk and make you install alot faster - Just a suggestion, hope this helps, Steve

Link to comment
Share on other sites

I am trying to find a command that simulates pressing the "Enter" key.

A few things come to mind:

1. From a batch file, you may be able to use this command

echo. | foobar

"echo." is a special command that submits a blank line. This only works if the program reads from standard input device (CON) and does not directly query the keyboard.

2. Try STUFFKEY.EXE, contained in the OzWoz utilities. Look for STUFFKEY here:

http://short.stop.home.att.net/freesoft/misc.htm

3. Smart Boot Manager (latest version is 3.7.1 at sourceforge) installs to the boot sector of your hard disk and lets you choose which partition to boot up. It also lets you create duplicate boot "records" which consist of both a partiton choice PLUS keystrokes to buffer when booting it. For example you can define a "Safe Windows" which boots your Windows partition as usual but also stuffs an F5 keystroke.

4. XOSL boot manager will also let you stuff keys while booting. This boot manager is prettier than Smart Boot Manager, but in addition to using the boot sector it requires placing some small files in a DOS partition as well.

Good luck.

Edited by azagahl
Link to comment
Share on other sites

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...