Simple code to retrive values
Function GetValues() As String
Dim pobjRegKey As RegistryKey
Dim pstrValue As String
pobjRegKey = Registry.LocalMachine.OpenSubKey("Software\Microsoft NT\CurrentVersion", False)
If Not IsNothing(pobjRegKey) Then
pstrValue = pobjRegKey.GetValue("ProductName", vbNullString).ToString
Return pstrValue
Else
Return vbNullString
End If
lblWindowsRevision.Text = pstrValue
End Function