当前位置:网站首页>QT wmic command obtains some hardware information
QT wmic command obtains some hardware information
2022-06-30 07:09:00 【HL_ Aeolus】
WMIC A large number of commonly used commands can be queried by Baidu
/* * obtain cpu name : wmic cpu get Name * obtain cpu The core number : wmic cpu get NumberOfCores * obtain cpu Number of threads : wmic cpu get NumberOfLogicalProcessors * obtain cpu Serial number : wmic cpu get processorid * Query the serial number of the motherboard : wmic baseboard get serialnunber * Inquire about bios Serial number : wmic bios get serialnunber * Check out the hard disk : wmic diskdrive get serialnunber */
QString getWMIC(const QString &cmd)
{
QProcess p;
p.start(cmd);
p.waitForFinished();
QString result = QString::fromLocal8Bit(p.readAllStandardOutput());
QStringList list = cmd.split(" ");
result = result.remove(list.last(),Qt::CaseInsensitive);
result = result.simplified();
return result;
}
边栏推荐
猜你喜欢

How to set the hot deployment of idea web project

IDEA import导入的类明明存在,却飘红?

2、 Layout system

Traverse map

I graduated this year, but I don't know what I want to do
![[JSON tutorial] Chapter 1 learning notes](/img/ce/cf74b396a8bd4c4c7028663b8cb665.png)
[JSON tutorial] Chapter 1 learning notes
![[fuzzy neural network] mobile robot path planning based on Fuzzy Neural Network](/img/39/c9bf235828b6d50e7931876fa4a918.png)
[fuzzy neural network] mobile robot path planning based on Fuzzy Neural Network

The maximum expression in Oracle database message list is 1000 error

经纬恒润再次荣获PACCAR集团 10PPM 质量奖
![[datawhale team learning] task02: mathematical operation, string and text, list](/img/3e/c9c984d7576a2e410da7f81a8c0aa6.jpg)
[datawhale team learning] task02: mathematical operation, string and text, list
随机推荐
我今年毕业,但我不知道我要做什么
Nested if statement in sum function in SQL Server2005
年轻人搞副业有多疯狂:月薪3000,副业收入3W
已解决:initialize specified but the data directory has files in it. Aborting
Which securities company is good for opening a mobile account? Also, is it safe to open an account online?
[Hot100]10. 正则表达式匹配
[my advanced OpenGL learning journey] about the access methods of vector and matrix classification of OpenGL shaders: xyzw/rgba/stpq and array subscripts
Egret engine P2 physics engine (2) - Funny physical phenomenon of small balls hitting the ground
app quits unexpectedly
【已解决】Failed! Error: Unknown error 1130
【申博攻略】五.专家推荐信模板
Servlet principle
First line of code (Third Edition) learning notes
Install the components corresponding to setup
Resolved: initialize specified but the data directory has files in it Aborting
【已解决】ERROR 1290 (HY000): Unknown error 1290
[docsify basic use]
6、 Shopping ⻋ and orders
leetcode:98. Validate binary search tree
Installation du serveur linux redis