Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
What is the Hard disk ID?
Message
De
25/03/2005 09:33:11
Hilmar Zonneveld
Independent Consultant
Cochabamba, Bolivie
 
 
À
25/03/2005 09:30:31
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Versions des environnements
Visual FoxPro:
VFP 7 SP1
Divers
Thread ID:
00999131
Message ID:
00999132
Vues:
38
This message has been marked as a message which has helped to the initial question of the thread.
Perhaps the GetVolumeInformation() API function?

http://news2news.com/vfp/?group=29&function=145

>I have that code which does the job
>
>
>oFS = CREATEOBJECT("Scripting.FileSystemObject")
>cDrive = SUBSTR(SYS(16,1),1,2) &&"C:"
>If oFS.DriveExists(cDrive)
>  oDrv = oFS.Drives.Item(cDrive)
>  lnvol=oDrv.SerialNumber
>  lnvolhex=substr(transform(lnvol,"@0"),3,4)+right(transform(lnvol,"@0"),4)
>  ?lnvolhex
>ENDIF
>
>
>What would be an alternative if WSH is not installed on a given machine?
Difference in opinions hath cost many millions of lives: for instance, whether flesh be bread, or bread be flesh; whether whistling be a vice or a virtue; whether it be better to kiss a post, or throw it into the fire... (from Gulliver's Travels)
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform