public class ProgramLauncher { private static void runFile(String fileName) { try { Runtime.getRuntime().exec("cmd /C start " + fileName); } catch (Exception e) { System.out.println(e); } } public static void main(String []arg) { // Ouvrir le fichier test.txt runFile("c:/test.txt"); // Ouvrir Microsoft Word runFile("winword"); } }