使用 Java 弹出 CD

发布于 2024-11-03 15:05:26 字数 150 浏览 5 评论 0原文

有没有简单的方法可以使用Java弹出Windows 7中的D驱动器?我目前并不特别关心跨平台兼容性。我做了一些研究,Runtime.getRuntime().exec(); 显示得最多......但我不知道该将什么作为字符串参数,我尝试了一些但它只是让我恶心!

Is there any simple way to eject the D drive in Windows 7 using Java? I don't particularly care about cross-platform compatibility at the moment. I've done some research andRuntime.getRuntime().exec(); has shown up most... but I have no idea what to put as the string parameter, I've tried a few things but it just throws up on me!

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

绝不服输 2024-11-10 15:05:26

您可以传递 vbscript 代码以弹出 cd 作为 exec() 函数中的参数。

You can pass the vbscript code to eject the cd as an argument in the exec() function.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文