Delete registry key: access denied

C

cyberco

WM5 PPC

In order to show the GPS Control Panel on my Tytn I have to delet the
registry key:

HKEY_LOCAL_MACHINE\ControlPanel\GPS Settings\Hide


But the following code:

RegistryKey registryKey =
Registry.LocalMachine.OpenSubKey(gpsRegistryKeyName);
registryKey.DeleteSubKey("Hide");
registryKey.SetValue("Group", "2",
RegistryValueKind.DWord);
registryKey.Close();

throws:

System.UnauthorizedAccessException:
UnauthorizedAccessException

Is it possible to delete this key at all?

2B
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top