When the program is over, I want it to say "Press any key to continue..." so I can scroll thru the output.
6 Answers
I believe you are looking for the command "pause". It should ask you to press any key.
You can even appear to change the prompt. Instead of just using the pause statement, you can:
echo "Your message here" pause > nul This gets rid of the original pause message and inserts yours.
Jacob
2 Comments
Create a shortcut to your batch file.
Right click on the file and select "Properties".
In the tab "Shortcut" is the target, something like this:
C:\folder\file.bat
Change it by this one:
C:\Windows\System32\cmd.exe /K "C:\folder\file.bat"
where "C:\Windows\System32" is the folder where cmd.exe is located, which may be another according to your Windows installation.
Then you can run the shortcut.