DECLARE FUNCTION GetVolumeInformation LIB "kernel32" _
ALIAS "GetVolumeInformationA" (lpRootPathName AS STRING, _
lpVolumeNameBuffer AS LONG, nVolumeNameSize AS LONG, _
lpVolumeSerialNumber AS LONG, lpMaximumComponentLength AS LONG, _
lpFileSystemFlags AS LONG, lpFileSystemNameBuffer AS STRING, _
nFileSystemNameSize AS LONG) AS LONG
DIM rtn AS LONG, flags AS LONG, fat$ AS STRING
fat$=SPACE$(50)
GetVolumeInformation("C:\", VARPTR(fat$), LEN(fat$), 0, VARPTR(rtn), _
VARPTR(flags), 0, LEN(fat$))
IF rtn=255 THEN SHOWMESSAGE("FAT supporting Long Names")
fat$=RTRIM$(fat$)
SHOWMESSAGE ("Drive C is called: "+fat$)
SHOWMESSAGE ("Flags: "+STR$(flags))
|