Is there any way one can control CD or CDRW drive such as Eject CD or eject CDR & leave data in original format and so on. I'd like to provide a function in my code to do what EasyCD Creator does where I can click on the icon in system tray to eject a CDR.
Private Declare Function mciSendString Lib "winmm.dll" _
Alias "mciSendStringA" _
(ByVal lpstrCommand As String, _
ByVal lpstrReturnString As String, _
ByVal uReturnLength As Long, _
ByVal hwndCallback As Long) As Long
Private Sub cmdTrayOut_Click()
x = mciSendString("set CDAudio door open", 0&, 0, 0)
End Sub
Private Sub cmdTrayIn_Click()
x = mciSendString("set CDAudio door closed", 0&, 0, 0)
End Sub
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.