比如是奔腾还是AMD等
请注意,这是来自VS2003:
using(ManagementObjectSearcher win32Proc = new ManagementObjectSearcher("select * from Win32_Processor"), win32CompSys = new ManagementObjectSearcher("select * from Win32_ComputerSystem"), win32Memory = new ManagementObjectSearcher("select * from Win32_PhysicalMemory")) { foreach (ManagementObject obj in win32Proc.Get()) { clockSpeed = obj["CurrentClockSpeed"].ToString(); procName = obj["Name"].ToString(); manufacturer = obj["Manufacturer"].ToString(); version = obj["Version"].ToString(); }