Strive to post and strive for promotion ^^
Small thing used to query the software registry information installed on the computer (test environment XP)
Everyone's interest and support made me do some improvements again (second modification on 07/10/26):
[ Last edited by PPdos on 2007-10-26 at 12:18 AM ]
Small thing used to query the software registry information installed on the computer (test environment XP)
@echo off
title Registry scanning...
mode con cols=50 lines=10
for /f "tokens=3 delims=\" %%i in ('reg query HKLM\SOFTWARE') do (
echo Current scanning information: HKLM\SOFTWARE\%%i
>>reglist.txt echo ================================================================
>>reglist.txt echo Software name:%%i
>>reglist.txt echo
================================================================
if not "%%i"=="Classes" for /f "tokens=4 delims=\" %%j in ('reg query HKLM\SOFTWARE\%%i 2^>nul') do (
echo Software information: %%j>>reglist.txt)
)
echo Scanning completed!
ping 127.0>nul
reglist.txtEveryone's interest and support made me do some improvements again (second modification on 07/10/26):
@echo off
mode con cols=50 lines=10
setlocal enabledelayedexpansion
set PPdos=HKLM HKCU
>%temp%\reglist.txt echo %DATE%%time% Registry scanning report
for %%h in (%PPdos%) do (
title Scanning: %%h item
for /f "tokens=3 delims=\" %%i in ('reg query "%%h\SOFTWARE"') do (
echo Current scanning information: %%h\SOFTWARE\%%i
>>%temp%\reglist.txt echo ================================================================
>>%temp%\reglist.txt echo Software name:%%i
>>%temp%\reglist.txt echo ================================================================
if not "%%i"=="Classes" if not "%%i"=="Microsoft" for /f "tokens=4 delims=\" %%j in ('reg query %%h\SOFTWARE\%%i 2^>nul') do (
echo Software information: %%j>>%temp%\reglist.txt
for /f "tokens=* delims=" %%k in ('reg query "%%h\software\%%i\%%j" /S^|findstr /c:"REG_SZ" ') do (
set /a n+=1
cls
echo Scanned item value: !n! Current information: %%j
echo Associated file information:%%k>>%temp%\reglist.txt )
)
)
)
)
>>%temp%\reglist.txt echo Tip: If you need to save the result, please save the file separately BY PPdos
title FINISHED&echo Scanning completed!
ping 127.0>nul
start %temp%\reglist.txt[ Last edited by PPdos on 2007-10-26 at 12:18 AM ]
Recent Ratings for This Post
( 1 in total)
Click for details
| Rater | Score | Time |
|---|---|---|
| ghostoyp | +1 | 2007-03-01 07:46 |
菩提本无树,明镜亦非台,本来无一物,何处惹尘埃.
