I'm creating a batch file to automatically run an setup.exe, the setup.exe requires Enter to be pressed once and then runs without assistance. Is it possible to have the batch file run the .exe and then automatically select enter for me?
To do this please follow the instructions below
Open notepad and paste this:
@echo off echo Press any key pause>nul echo what is your username? set /p user= echo what is your password? set /p pass= If '%user%'=='Tspider4' goto gooduser echo WRONG USERNAME AND PASSWORD echo Press a key to exit pause>nul :gooduser If '%pass%'=='youtube' goto good echo WRONG PASSWORD echo Press a key to exit pause>nul :good echo GOOD echo Wanna start notepad!? set /p note= If '%note%'=='yes' start notepad.exe echo byebye pause>nule exit
Click save as
Give the name "Program.bat"
When you open this file you just follow what the batch file is asking you
"Press any key"
"what is your user name?"
(type this) Tspider4
"what is your password"
(type this) youtube
Wanna start notepad?
(type this) yes
(and notepad will open automatically....) now if u wish to open WINDOWS LIVE MESSENGER u just ha to rewrite this "echo Wanna start notepad!?" for "echo Wanna start msnmgr!?"