你好,能不能麻烦您帮我写一个收集电脑配置的批处理
@echooff&title获取本机简要配置信息By依梦琴瑶::设置信息保存路径setLog=C:\某个文件夹\本机简要配置信息.txtechoWScript.EchoW...
@echo off & title 获取本机简要配置信息 By 依梦琴瑶
::设置信息保存路径
set Log=C:\某个文件夹\本机简要配置信息.txt
echo WScript.Echo Wscript.Arguments(0) / (1024 * 1024 * 1024)>Calculation.vbs
echo 正在获取信息中 ...
(for /f "tokens=2 delims==" %%a in ('wmic csproduct get Name /value ^| findstr /i "Name"') do echo 电脑型号:%%~a
for /f "tokens=2 delims==" %%a in ('wmic csproduct get Vendor /value ^| findstr /i "Vendor"') do echo 制 造 商:%%~a
for /f "tokens=2 delims==" %%a in ('wmic csproduct get IdentifyingNumber /value ^| findstr /i "IdentifyingNumber"') do echo SN序列号:%%~a
echo 登 录 名:%USERNAME%
echo 计算机名:%COMPUTERNAME%
for /f "tokens=2 delims==" %%a in ('wmic cpu get Name /value ^| findstr /i "Name"') do echo 处 理 器:%%~a
for /f "tokens=2 delims==" %%a in ('wmic memorychip get Capacity /value ^| findstr /i "Capacity"') do (
for /f "tokens=1 delims=." %%b in ('cscript /nologo Calculation.vbs "%%~a"') do set /a m+=%%~b
)
call echo 内存容量:%%m%% GB
for /f "tokens=2 delims==" %%a in ('wmic DiskDrive get Size /value ^| findstr /i "Size"') do (
for /f "tokens=1 delims=." %%b in ('cscript /nologo Calculation.vbs "%%~a"') do set /a d+=%%~b
)
call echo 硬盘容量:%%d%% GB
for /f "tokens=2 delims==" %%a in ('wmic nic where "netconnectionid!=NULL" get macaddress /value ^| findstr /i "MACAddress"') do echo MAC 地址:%%~a)>"%Log%"
del Calculation.vbs
echo 信息获取,并保存。
pause
这是您以前写的一个,我想增加一条显卡,麻烦您了 展开
::设置信息保存路径
set Log=C:\某个文件夹\本机简要配置信息.txt
echo WScript.Echo Wscript.Arguments(0) / (1024 * 1024 * 1024)>Calculation.vbs
echo 正在获取信息中 ...
(for /f "tokens=2 delims==" %%a in ('wmic csproduct get Name /value ^| findstr /i "Name"') do echo 电脑型号:%%~a
for /f "tokens=2 delims==" %%a in ('wmic csproduct get Vendor /value ^| findstr /i "Vendor"') do echo 制 造 商:%%~a
for /f "tokens=2 delims==" %%a in ('wmic csproduct get IdentifyingNumber /value ^| findstr /i "IdentifyingNumber"') do echo SN序列号:%%~a
echo 登 录 名:%USERNAME%
echo 计算机名:%COMPUTERNAME%
for /f "tokens=2 delims==" %%a in ('wmic cpu get Name /value ^| findstr /i "Name"') do echo 处 理 器:%%~a
for /f "tokens=2 delims==" %%a in ('wmic memorychip get Capacity /value ^| findstr /i "Capacity"') do (
for /f "tokens=1 delims=." %%b in ('cscript /nologo Calculation.vbs "%%~a"') do set /a m+=%%~b
)
call echo 内存容量:%%m%% GB
for /f "tokens=2 delims==" %%a in ('wmic DiskDrive get Size /value ^| findstr /i "Size"') do (
for /f "tokens=1 delims=." %%b in ('cscript /nologo Calculation.vbs "%%~a"') do set /a d+=%%~b
)
call echo 硬盘容量:%%d%% GB
for /f "tokens=2 delims==" %%a in ('wmic nic where "netconnectionid!=NULL" get macaddress /value ^| findstr /i "MACAddress"') do echo MAC 地址:%%~a)>"%Log%"
del Calculation.vbs
echo 信息获取,并保存。
pause
这是您以前写的一个,我想增加一条显卡,麻烦您了 展开
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询