I've got a Java application, that I startup from the command prompt using a .bat file, contents look as follows :
cls
rem Starting app
set CLASSPATH=.;.\lib\
title App1 starting
java app/StartMe
It will then startup, and print output to the command window. If I want to stop the app I have to Control + C, and type Y. This is quite annoying, as I want to start/stop in a loop and I currently have to do this manually
How can I introduce a pause of 30 seconds, and then stop the Java app?
I've tried appending exit /B to the above script, but that doesn't seem to do anything, what can I do to add a wait/sleep, and then stop the Java process?
Thanks