Try to do this.
Dim l_subKeyPath As String = "Software\Microsoft\Windows NT\CurrentVersion\Windows"
Dim l_regKey = My.Computer.Registry.CurrentUser.OpenSubKey(l_subKeyPath)
If l_regKey Is Not Nothing Then
Dim deviceValue as String = l_regKey.GetValue("Device")
//
Else
End If
Your code has problem as you have provided complete path of registry key with its value. Also your code contain HKEY_USers\S-1-5-18 which is not required if you use Registry.CurrentUser