Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
What is the Hard disk ID?
Message
From
25/03/2005 10:02:07
 
 
To
25/03/2005 09:33:11
Hilmar Zonneveld
Independent Consultant
Cochabamba, Bolivia
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Environment versions
Visual FoxPro:
VFP 7 SP1
Miscellaneous
Thread ID:
00999131
Message ID:
00999139
Views:
42
Thank you Hilmar. The funny thing is that before asking that question I went to News2News. But I did'nt look at the right place.

>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?
*******************************************************
Save a tree, eat a beaver.
Denis Chassé
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform