How to get hardware information in Windows using C++?

无人久伴 提交于 2019-12-03 07:11:43

There are very different ways to get a disk id (serial number? volume id?) or a CPU ID or ... . I think you want to build a fingerprint of the computer. The most comfortable way is to use Windows Management Instrumentation (WMI) and access the DMI . See MSDN for a start. See MSDN here for a hint how to get the mainboard serial number as an example.

GetSystemInfo will get you started with the CPU information. Each subsystem generally has different query functions.

The standard c++ don`t provide this for you. These api may be provided by os or hardware driver.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!