Read registry key

前端 未结 2 388
没有蜡笔的小新
没有蜡笔的小新 2021-01-29 04:40

Am I doing something wrong? I get no value back...

Imports Microsoft.Win32
...
Dim s As String = \"\"
Dim reg As RegistryKey

reg =Registry.LocalMachine.OpenSubK         


        
2条回答
  •  终归单人心
    2021-01-29 05:16

    Try messagebox.show(s.ToString)

    Wehn you compile to 32 bit on a 64 bit OS, when the key will be created in the HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\ node. However, the app that creates it should be able to read it back, even if you can't find it where you expected to in RegEdit.exe

提交回复
热议问题