Not Working RegistryKey.openSubKey in windows 7
-
Hi, RegistryKey.openSubKey("KeyName",true) working in windows XP , but it is not working in Windows 7 32 bit. we are getting error : no rights to read.Please suggest me better way
-
Hi, RegistryKey.openSubKey("KeyName",true) working in windows XP , but it is not working in Windows 7 32 bit. we are getting error : no rights to read.Please suggest me better way
I have just tested it with Win 7 from the MSDN example, and it is working fine. The MSDN site recommends using
Registry.CurrentUser.OpenSubKey("yourKeyName", true);
maybe that is an issue.
...and I have extensive experience writing computer code, including OIC, BTW, BRB, IMHO, LMAO, ROFL, TTYL.....
-
Hi, RegistryKey.openSubKey("KeyName",true) working in windows XP , but it is not working in Windows 7 32 bit. we are getting error : no rights to read.Please suggest me better way
Windows, since Vista, protects those entries that affect all users, so you can't just access some of the hives (e.g. LOCAL_MACHINE) any more, unless you get the required privileges and go through UAC. I don't have all the details, I suggest you Google. The CURRENT_USER hive works just fine. And the way the protection works is different on 64-bit systems, I haven't figured that one out at all. :)
Luc Pattyn [My Articles] Nil Volentibus Arduum
The quality and detail of your question reflects on the effectiveness of the help you are likely to get.
Please use <PRE> tags for code snippets, they improve readability.
CP Vanity has been updated to V2.3 -
Windows, since Vista, protects those entries that affect all users, so you can't just access some of the hives (e.g. LOCAL_MACHINE) any more, unless you get the required privileges and go through UAC. I don't have all the details, I suggest you Google. The CURRENT_USER hive works just fine. And the way the protection works is different on 64-bit systems, I haven't figured that one out at all. :)
Luc Pattyn [My Articles] Nil Volentibus Arduum
The quality and detail of your question reflects on the effectiveness of the help you are likely to get.
Please use <PRE> tags for code snippets, they improve readability.
CP Vanity has been updated to V2.3Luc Pattyn wrote:
The CURRENT_USER hive works just fine.
Unless you're running an app over the network on a terminal and/or VPN. At least, it wouldn't the current user access the HKCU hive when remoting in on the systems here.
Never give aversion therapy to a masochist. The results are unpredictable. My Mu[sic] My Films My Windows Programs, etc.