Each time I use Runtime.exec('cmd /c start....') I am opening a cmd window. I would like to create a more seamless application by closing each previous cmd window. How can I do this?
If anyone knows of a better way to run a series of commands in the same cmd window rather than opening new ones each time I execute a command, please let me know.
You cannot control the opened windows from Java. But I suggest two solutions for you:
First:
The /MIN parameter will prevent windows from appearing.
Second: put all the applications you must call inside the same batch file and call it once. 🙂