J
JB
I am trying to access a registry key on computer like so:
key = RegistryKey.OpenRemoteBaseKey(RegistryHive.LocalMachine,
computerName).OpenSubKey(Subkey);
There are two keys I am trying to read, 1 works, and the other gives
me the "Requested registry access is not allowed."
i've narrowed it down to
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Office
It doesnt let me access that path, but the permissions are the same.
I can access it alright on my own machine (passing my machine name
into OpenRemoteBaseKey) but not anyone's remote machine.
It lets me access HKLM\Software\Microsoft\Windows NT
but not
HKLM\Software\Microsoft\Office
Although I get the same error "Requested registry access is not
allowed" if i enter an incorrect path, eg HKLM\Software\fdjkhfjkh
Any ideas where i may be going wrong?
key = RegistryKey.OpenRemoteBaseKey(RegistryHive.LocalMachine,
computerName).OpenSubKey(Subkey);
There are two keys I am trying to read, 1 works, and the other gives
me the "Requested registry access is not allowed."
i've narrowed it down to
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Office
It doesnt let me access that path, but the permissions are the same.
I can access it alright on my own machine (passing my machine name
into OpenRemoteBaseKey) but not anyone's remote machine.
It lets me access HKLM\Software\Microsoft\Windows NT
but not
HKLM\Software\Microsoft\Office
Although I get the same error "Requested registry access is not
allowed" if i enter an incorrect path, eg HKLM\Software\fdjkhfjkh
Any ideas where i may be going wrong?