【发布时间】:2013-06-25 22:55:48
【问题描述】:
如何关闭打开的excel文件?
打开excel代码是:
File file = new File("e:\\aaa.xlsx");
Desktop desktop = Desktop.getDesktop();
desktop.open(file);
什么是关闭代码?
只需像使用鼠标一样使用 java 打开和关闭 Windows 应用程序。
【问题讨论】:
-
顺便说一句
new File("e;\\aaa.xlsx");应该是new File("e:\\aaa.xlsx"); -
@JoopEggen 既然是答案,为什么不将其升级为答案呢?