I am programming with Visual Basic in Visual Studio 2010. The following code returns null for rk
Dim SoftwareKey As String
Dim rk As RegistryKey
SoftwareKey = "SOFTWARE\Microsoft\Windows\CurrentVersion\Installer\UserData\S-1-5-18\Products"
rk = Registry.LocalMachine.OpenSubKey(SoftwareKey)
However, I know that the sub key exists because I can see it when I run regedit.exe, the registry editor. What am I doing wrong?
Are you running an app compiled for x86 on a 64-bit machine??
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)