`
happmaoo
  • 浏览: 4345084 次
  • 性别: Icon_minigender_1
  • 来自: 杭州
社区版块
存档分类
最新评论

用VbScript控制光驱

阅读更多
<html>光驱
<head>
<title>光驱控制</title>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
</head>
<body>
<script language="vbscript">
<!--
Set Player = CreateObject("WMPlayer.OCX.7" )
i=1
Function eject()
if i=1 then
EJECTBUTTON.value = "收回光驱"
i=2
else
EJECTBUTTON.value = "弹出光驱"
i=1
end if
Player.cdromCollection.item(0).eject()
EJECTBUTTON.blur()
end Function
-->
</SCRIPT>
<INPUT TYPE = "BUTTON" NAME = "EJECTBUTTON" id = "EJECTBUTTON" value = "弹出光驱" onClick ="eject()">
</body>
</html>
分享到:
评论

相关推荐

Global site tag (gtag.js) - Google Analytics