Runtime run = new Runtime.getRuntime();
Process p = run.exec("notepad.exe F:\lesson\a.java"); //启动进程
Thread.sleep(5000); //5s后关闭
p.destroy();
Runtime run = new Runtime.getRuntime();
Process p = run.exec("notepad.exe F:\lesson\a.java"); //启动进程
Thread.sleep(5000); //5s后关闭
p.destroy();