Click to See Complete Forum and Search --> : Registry


draj
July 16th, 2003, 11:14 AM
How can I get the value of a (Default) from a RegistryKey.
I tried using GetValue function. But it returns null.

Can anybody help me on Registry reading functions?

thanks,
raj

poochi
July 17th, 2003, 11:26 AM
RegistryKey regkey = Registry.CurrentUser.OpenSubKey("<KEY>", false);
object obj = regkey.GetValue(""); // << retrieves (Default) value.


if the (Default) value is not set, it will return null.

draj
July 18th, 2003, 12:12 PM
Poochi,
Thanks for the reply.
I found in the help also. They had given the same solution.

Raj