Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Hard disk serial number
Message
 
À
24/09/1999 21:23:56
Information générale
Forum:
Visual FoxPro
Catégorie:
Fonctions Windows API
Divers
Thread ID:
00268851
Message ID:
00269247
Vues:
16
DECLARE INTEGER GetVolumeInformation IN WIN32API AS GetVolInfo STRING@, STRING@, INTEGER, INTEGER@, INTEGER@, INTEGER@, STRING@, INTEGER

lpRoot = SYS(5) + '\'
lpVolumeBuffer = SPACE(256)
nVolumeNameSize = 256
lpSerialNumber = 0
lMaxLength = 256
lpSystemFlag = 0
lpSystemBuffer = SPACE(256)
nSystemNameSize = 256

nSuccess = GetVolInfo(@lpRoot, @lpVolumeBuffer, nVolumeNameSize, @lpSerialNumber, @lMaxLength, @lpSystemFlag, @lpSystemBuffer, nSystemNameSize)

cVolumeName = LEFT(ALLTRIM(lpVolumeBuffer),LEN(ALLTRIM(lpVolumeBuffer))-1)
cSerialNumber = ALLTRIM(STR(lpSerialNumber))


>I saw a post may a year or two ago that had an API call to return the hard disk serial number. I can't seem to locate any such reference in the MSDN help behemoth.
>Anyone remember it?
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform