Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Wanet Telecoms Ltd on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Open CD Tray with VBScript 3

Status
Not open for further replies.

GRXboxers

Programmer
Feb 9, 2005
9
NL
Hey I'm looking for a VBScript code that can open a CD tray.
I knew the code a longtime ago but I lost it. Can someone help me?
 
Did you search? It is all over the web.

[red]"... isn't sanity really just a one trick pony anyway?! I mean, all you get is one trick, rational thinking, but when you are good and crazy, oooh, oooh, oooh, the sky is the limit!" - The Tick[/red]
 
here's what you need:


Set wmp = CreateObject("WMPlayer.OCX.7" )
Set CDROMs = wmp.cdromCollection
if CDROMs.Count >= 1 then
For i = 0 to CDROMs.Count - 1
CDROMs.Item(i).Eject
Next
End If
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top