level 1
偶知道一段,希望对你有帮助...Option ExplicitPrivate Declare Function CDdoor Lib "winmm.dll" Alias "mciSendStringA" _ (ByVal lpstrCommand As String, ByVal lpstrReturnString As String, _ ByVal uReturnLength As Long, ByVal hwndCallback As Long) As LongDim state1 As BooleanPrivate Sub Command1_Click()'打开光驱 state1 = True Call CDdoor("set CDAudio door open", 0, 0, 0)End SubPrivate Sub Command2_Click()'关闭光驱 state1 = False Call CDdoor("set CDAudio door closed", 0, 0, 0)End SubPrivate Sub Command3_Click() EndEnd Sub
2007年11月19日 14点11分