Windows – How to find and delete multiple Windows registry entries

cmd.exewindowswindows-registry

I need to clean the Windows registry after manually removing a program. What I need to do is following.

  1. Find all keys, values, and data containing "something".
  2. Delete all keys, values, and data matching the description.

Can I use the Reg command in CMD for this somehow?

By "something" in this case, I mean "office12".

Best Answer

Try Powershell:

Get-ChildItem -path HKLM:\ -Recurse | where { $_.Name -match 'office12'} | Remove-Item -Force

This will traverse recursively throw HKEY_LOCAL_MACHINE and delete all matching keys. More info here

Related Question