Home Technical Index

Windows Registry

Deleting Keys and Values using a .REG script

I have searched for ages in the past for a way of removing Windows Registry values and whole keys using .REG script files. Having found out how to do it I thought I ought to publicise the method.

Adding a registry value, including the default value (we all know how to do this):

	REGEDIT4

	[HKEY_CURRENT_USER\Software\Wibble Software]
	@="12"
	"Something"="123"

Removing the values again:

	REGEDIT4

	[HKEY_CURRENT_USER\Software\Wibble Software]
	@=-
	"Something"=-

Or removing the whole key:

	REGEDIT4

	[-HKEY_CURRENT_USER\Software\Wibble Software]

Easy as that!


Home Technical Index Valid HTML 4.01!