JAVA - continues application run
问题 I have the following code. public static void main(String args[]){ ProcessBuilder pb = new ProcessBuilder("java","-xmx768m","DesDatMain","anArgument"); pb.directory(new File(".")); try{ Process process = pb.start(); } catch(IOException e){ e.printStackTrace(); } SwingUtilities.invokeLater(new Runnable(){public void run(){new JFrame();}}); } If I run it in “home” folder (containing source files etc.) it will continuously run one app by one app. The same result has executable jar. But if I move