Original Post
I'm programming an application in C# 2005 which makes use of the registry. The problem is I don't know how to display string array values! Here's what I have: If you look up that key in the registry you'll understand what I mean. How do I adapt my code to display all the contents of the string arrays?
RegistryKey myKey = Registry.LocalMachine.OpenSubKey("SYSTEM\\ControlSet001\\Services\\lanmanserver\\Shares");
foreach (string shared in myKey.GetValueNames())
{
MessageBox.Show(myKey.GetValue(shared).ToString());
lvShared.Items.Add(shared);
}
myKey.Close();