Реферат: Конфигурация аппаратных средств персонального компьютера
Err.Clear
End Sub
Sub GetDiskInfo()
n = 0
For i = 65 To 90
If GetDriveType(Chr$(i) & ":" & "\") <> 1 Then n = n + 1: Drives(n) = Chr$(i) & ":" & "\"
Next i
For i = 1 To n
Call GetDiskFreeSpace(Drives(i), SecsPerClus(i), BytesPerSec(i), NumOfFreeClus(i), TotalNumOfClus(i))
Select Case GetDriveType(Drives(i))
Case DRIVE_CDROM
TypeOfDrive(i) = "CD-ROM"
Case DRIVE_REMOVABLE
TypeOfDrive(i) = "Floppy disk"
Case DRIVE_FIXED
TypeOfDrive(i) = "Hard disk drive"
Case DRIVE_RAMDISK
TypeOfDrive(i) = "Virtual disk"
Case DRIVE_REMOTE
TypeOfDrive(i) = "Net disk"
Case Else
End Select
Next
For i = 1 To n
VNBuffer(i) = Space$(255)
VNSize(i) = 255
vSysBuff(i) = Space$(255)
vSysSize(i) = 255
vFlags(i) = 0