Sujeet Suman

Sujeet Suman

  • 388
  • 4.1k
  • 1.5m

Unable to open registry subkey On windows 10 PC using C#

Jul 13 2017 3:38 AM
I unable to open programmatically registry subkey on windows 10 PC.
 
I am getting exception by using below code.
 

using (RegistryKey keys = Registry.LocalMachine.OpenSubKey(a_Path,      RegistryKeyPermissionCheck.ReadWriteSubTree, RegistryRights.FullControl))

{
      // Doing some operation like  reading some value
}
 
Exception:

Requested registry access is not allowed.

Can any body help me to come out. 
 

Answers (7)