Monday, 22 April 2013

Open A (.app) File Extension In Java

import java.io.IOException;

public class OpenApp {

public static void main(String arg[]) {
try{
Process p = Runtime.getRuntime().exec("open /Users/Arun/Desktop/MyFirst.App"); // pass Your .app path
} catch (IOException ex) {
ex.printStackTrace();
Logger.getLogger(FileManageUI.class.getName()).log(Level.SEVERE, null, ex);

}            

}

}