I am attempting to delete a key under HKCU/software. I am getting the following error:
"Cannot write to the registry key" error.
The key located under "software" is named Parent. The key I would like to delete is named "Child" and is located as a subkey under Parent.
Any ideas how I can fix this ?
Thanks.
"Cannot write to the registry key" error.
The key located under "software" is named Parent. The key I would like to delete is named "Child" and is located as a subkey under Parent.
VB.NET:
[size=2]
regKey = Registry.CurrentUser.OpenSubKey("software\Parent", [/size][size=2][color=#0000ff]False[/color][/size][size=2])
'If key does exist
[/size][size=2][color=#0000ff]If[/color][/size][size=2][color=#0000ff]Not[/color][/size][size=2] (regKey [/size][size=2][color=#0000ff]Is[/color][/size][size=2][color=#0000ff]Nothing[/color][/size][size=2]) [/size][size=2][color=#0000ff]Then
[/color][/size][size=2]regKey.DeleteSubKey("CHILD", [/size][size=2][color=#0000ff]True[/color][/size][size=2])
[/size]
Any ideas how I can fix this ?
Thanks.