|
- @echo off
- setlocal ENABLEDELAYEDEXPANSION
- echo.
- echo.
- echo 获取系统名称....
- set verz=0
- FOR /f "tokens=2* delims= " %%b in ('reg query "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion" /v "PRODUCTNAME" 2^>nul') do (set "verx=%%c")
- if "!verx!"=="" (for /f "tokens=2 delims==^|" %%c in ('wmic os get name /value ') do ( set "verx=%%c" ))
- for /f "tokens=4 delims=[] " %%c in ('ver') do (if not "%%c"=="" set "very=%%c")
- FOR /f "tokens=2* delims= " %%b in ('reg query "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion" /v "ReleaseId" 2^>nul') do (set "verz=%%c")
- ECHO.
- ECHO 当前系统: %verx% / %very% / %verz%
- pause>nul
复制代码
ver_xyz.7z
(488 Bytes, 下载次数: 7)
|
|