帮助我看看这个程序是什么问题,在线等待????
msnkk 2003-02-11 09:59:40 import java.io.BufferedInputStream;
import java.io.IOException;
import java.io.InputStream;
public class Exe1{
public static void main(String args[]){
Runtime runtime = Runtime.getRuntime();
try {
String com[]=new String[4];
com[0] = "command.com";
com[1] = "/C";
com[2] = "del";
com[3] = "D:\\AA\\2.txt";
Process process = runtime.exec(com);
process.waitFor();
process.destroy() ;
} catch (Exception e) {
System.err.println("runtime.exec error");
e.printStackTrace();
}
}
}