Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Processot ID or Serial Number
Message
 
To
06/05/2004 04:42:50
Cetin Basoz
Engineerica Inc.
Izmir, Turkey
General information
Forum:
Visual FoxPro
Category:
Other
Miscellaneous
Thread ID:
00901466
Message ID:
00901621
Views:
19
>>Hi All
>>
>>How to get the Processor or CPU serial number and other information of it
>>
>>Thanks
>>Anwar
>
>Using WMI.
>Only some processors have a CPU serial feature. IOW accept you can't.
>Cetin


And the code will be something like this (some properties only):
local loWMIService, loCPUs, loCPU

loWMIService	= GetObject("winmgmts:\\.\root\cimv2")
loCPUs		= loWMIService.ExecQuery("Select * from Win32_Processor")

For Each loCPU in loCPUs
	with loCPU
		? 'CPU Id		', .ProcessorID
		? 'Name			', .Name
		? 'AddressWidth		', .AddressWidth
		? 'Architecture		', .Architecture
		? 'Caption		', .Caption
		? 'CurrentClockSpeed	', .CurrentClockSpeed
		? 'DataWidth		', .DataWidth
		? 'ExtClock		', .ExtClock
		? 'Family		', .Family
		? 'Version		', .Version
		? 'UpgradeMethod	', .UpgradeMethod
   endwith 
endfor
< EDIT>

Oops, sorry Cetin, the message was intended to be send to the original poster :(

< /EDIT>
"The five senses obstruct or deform the apprehension of reality."
Jorge L. Borges?

"Premature optimization is the root of all evil in programming."
Donald Knuth, repeating C. A. R. Hoare

"To die for a religion is easier than to live it absolutely"
Jorge L. Borges
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform