-
-
Save gialloporpora/4572776 to your computer and use it in GitHub Desktop.
@echo off | |
REM Reference: http://www.techrepublic.com/forum/questions/101-215911/dos-command-to-list-all-installed-programs | |
echo ================= >>software_list.txt | |
reg export HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall temp1.txt | |
find "DisplayName" temp1.txt| find /V "ParentDisplayName" > temp2.txt | |
for /f "tokens=2,3 delims==" %%a in (temp2.txt) do (echo %%a >> software_list.txt) | |
del temp1.txt | |
del temp2.txt | |
REM type software_list.txt | more | |
echo. | |
echo. | |
echo Installed software are stored in software_list.txt |
I like this and it works great! However can we modify that to show a list of maybe 3 different criteria? For example line 5 I modified it to look like this: find "Microsoft" temp1.txt| find /V "ParentDisplayName" > temp2.txt
I would like to modify that to show more specific programs like: find "Microsoft" temp1.txt| find "Adobe" temp2.txt| find "BIRT" temp3.txt| "find /V "ParentDisplayName" > temp4.txt
I can show the list if I only search for one criteria such as "Microsoft" but I wanted to create a list showing "Microsoft", "Adobe", "BIRT"... is this possible?
To generate the list of installed programs, open the Command Prompt as Administrator. To do this, click on Start, type in cmd and then right-click on Command Prompt and choose Run as Administrator.
At the command prompt, type in wmic (wmic is the Windows Management Instrumentation Command-line tool) and press Enter.
Enter the following line (copy and paste) at the wmic:root\cli prompt and press Enter.
/output:C:\InstallList.txt product get name,version
NOTE: There is a space between .txt and product, between product and get, and between get and name.
You can also change the name of the output file and drive letter and path (right after /output:) if you want to modify the output location.
awesome!