如何检测CD驱动器在Windows服务中是否打开或关闭 [英] how to detect CD Drive is opened or close in windows service

查看:123
本文介绍了如何检测CD驱动器在Windows服务中是否打开或关闭的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述


在我的项目中,我想通知CD驱动器何时打开和关闭.
这必须通过服务来完成.插入CD时,我要查找特定文件.如果该文件存在于插入的CD中,则必须禁用自动播放功能,并且必须从该服务中执行我的exe文件.请帮助我该怎么做.

Hi,
In my project, I want to notify when CD drive is opened and closed.
This must be done through a service.When Cd is inserted i want to look for specific file.If that file is present in that Inserted CD then Auto play must be disabled and my exe File must be executed from the service. please help me how to do that.

推荐答案

此链接可能会对您有所帮助.

http://msdn.microsoft.com/zh-CN /library/windows/desktop/aa394132(v=vs.85).aspx [
This link might help you.

http://msdn.microsoft.com/en-us/library/windows/desktop/aa394132(v=vs.85).aspx[^]


这篇关于如何检测CD驱动器在Windows服务中是否打开或关闭的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆