String f="c:\\rpaths.txt";
Runtime r = Runtime.getRuntime();
try {
r.exec("start " + f);
}
catch (IOException ex) {
}
这么做打不开,该怎么操作???
Runtime r = Runtime.getRuntime();
try {
r.exec("start " + f);
}
catch (IOException ex) {
}
这么做打不开,该怎么操作???
解决方案 »
- 线程stop的时候,显示The method stop() is deprecated会有什么后果?
- 目前对 hadoop 的前景了解甚少,不知道他的前途如何,有经验的给点建议啊
- Hibernate createSqlQuery().list()查出来的结果被截取了
- Cookies
- java.lang.ClassNotFoundException: org.apache.log4j.Category
- JAVA 中String类型的一点小问题
- Solaris操作系统下调用WebService救急
- About DynaActionForm, thank you
- hibernate的疑问?
- 通过Socket通信处理XML时遇到的问题,请指教
- 安装tomcat5.5.4无法运行
- 关于JAVA文件保存的问题(急急急!!!)
public static void main(String[] arg){
String f="1.txt";
Runtime r = Runtime.getRuntime();
try {
r.exec("notepad "+f);
}
catch (Exception ex) {
}
}}
class A{
public static void main(String[] arg){
String f="1.doc";
Runtime r = Runtime.getRuntime();
try {
r.exec("C:\\Program Files\\Microsoft Office\\OFFICE11\\WINWORD.EXE "+f);
}
catch (Exception ex) {
}
}}C:\\Program Files\\Microsoft Office\\OFFICE11\\WINWORD.EXE 是你word的安装路径.