Select Case Drive("I:\").FileSystem
Case "CDFS"
MsgBox "Вставлен CD"
Case "UDF"
MsgBox "Вставлен DVD"
Case Else
MsgBox "Чё вы за фигню в привод запихали???"
End Select
Declare Function SetWindowsHookEx Lib "user32" Alias "SetWindowsHookExA" (ByVal idHook As Long, ByVal lpfn As Long, ByVal hmod As Long, ByVal dwThreadId As Long) As Long
RayShade писал(а):Будущему тебе
Function ShowFileSystemType(drvspec)
Dim fso,d
Set fso = CreateObject("Scripting.FileSystemObject")
Set d = fso.GetDrive(drvspec)
ShowFileSystemType = d.FileSystem
End Function
HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\CD Burning\Drives
alibek писал(а):И что в ней интересного?
120 Set cn = New ADODB.Connection
130 cn.ConnectionString = "Provider=MSDASQL.1;Persist Security Info=False;Extended Properties=""DSN=w;DBQ=root\CIMV2;SERVER=;UIDPWDDEFINED=;UID=;SYSPROPS=FALSE;NAMESPACES={root\CIMV2,deep}"""
cn.CursorLocation = adUseClient
140 cn.Open
Set Rs = New ADODB.Recordset
Rs.CursorLocation = adUseClient
Set Rs.ActiveConnection = cn
Rs.Open "SELECT * FROM CIM_MediaAccessDevice", , adOpenStatic, adLockReadOnly, adCmdText
160 Set Me.DataGrid1.DataSource = Rs
Сейчас этот форум просматривают: Google-бот, Mail.ru [бот] и гости: 16