We are facing trouble restarting closing a running *.JAR file started with the "java -cp"
.
Killing java.exe worked fine.
But... isn't there any smoother way for the application? (It saves data on shut-down)
Also, how can one simulate any key input at the following message "Enter any key to continue..."
with a batch file?
Thanks for all help!
The following set of batch scripts can be used to start/stop jars/any program
start-jar.bat
start "win_title" java -jar [jar file] [jar options]
this basically starts your jar(the program) in a window with title set to "win_title".
you could use another batch to kill the window started
stop-jar.bat
TASKKILL /FI "WINDOWTITLE eq win_title
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With