Returns an array containing the enumerated drives.
DriveGetDrive ( "type" )
@error is set to 1 if the parameter is neither a $ constant nor a string equivalent, or if the computer has no drives of the requested type.
Example: On a computer that has no CD/DVD drive, DriveGetDrive("CDROM") sets @error to 1
DriveGetFileSystem, DriveGetLabel, DriveGetSerial, DriveGetType, DriveSetLabel, DriveSpaceFree, DriveSpaceTotal, DriveStatus
#include <AutoItConstants.au3>
#include <MsgBoxConstants.au3>
Local $aArray= DriveGetDrive ($DT_ALL)
If @error Then
; An error occurred when retrieving the drives.
MsgBox ($MB_SYSTEMMODAL,"","It appears an error occurred.")
Else
For $i= 1To $aArray[0]
; Show all the drives found and convert the drive letter to uppercase.
MsgBox ($MB_SYSTEMMODAL,"","Drive "&$i&"/"&$aArray[0]&":"&@CRLF &StringUpper ($aArray[$i]))
Next
EndIf