我正在尝试使用java打开exe文件。我不确定要打开哪个程序,因此我使用 Skype 作为示例。当我尝试这样做时,它给了我错误。
try {
Process p = Runtime.getRuntime().exec("C:\\Program Files (x86)\\Skype\\Phone\\Skype");
} catch (IOException e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
Run Code Online (Sandbox Code Playgroud)
错误:无法运行程序“C:\Program”: CreateProcess error=2,系统找不到指定的文件