0
Thanks

A few words of thanks would be greatly appreciated.

Windows - A .bat file to delete a particular registry key



Issue


I need to create a .bat file that will remove registry a particular registry key, when you double click on it:
[HKEY_LOCAL_MACHINE\SOFTWARE\Classes\CLSID\{64A3D41B-61A5- 4834-9A42-FDE1C37B0008}]

Solution


Create a text file containing the following:
Windows Registry Editor Version 5.00
[-HKEY_LOCAL_MACHINE\SOFTWARE\Classes\CLSID\{64A3D41B-61A5- 4834-9A42-FDE1C37B0008}]
  • Name it as key.reg

Create another text file with the following content:
regedit /s key.reg
  • Name it as delete.bat .
  • Run the second file as admin.

Thanks to kaumune for this tip.
0
Thanks

A few words of thanks would be greatly appreciated.

Ask a question
Jean-François Pillou

CCM is a leading international tech website. Our content is written in collaboration with IT experts, under the direction of Jeff Pillou, founder of CCM.net. CCM reaches more than 50 million unique visitors per month and is available in 11 languages.

Learn more about the CCM team

Published by . Latest update on by jak58.

This document, titled "Windows - A .bat file to delete a particular registry key," is available under the Creative Commons license. Any copy, reuse, or modification of the content should be sufficiently credited to CCM (https://ccm.net/).

0 Comments