Click here to Skip to main content
15,878,809 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
Hi Team,
I want to convert the following vbscript function to javascript.
I am reading a registry values in it. Some may say its not secure to read registry, I still want to read it.

JavaScript
<script type="text/vbscript">

  Function SayHello()
    MsgBox "Hello"

HKEY_LOCAL_MACHINE = "&H80000002"
uninstallRegKey = "SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\Uninstall"
stdRegPro = "winmgmts:{impersonationLevel=impersonate}!\\\\.\\root\\default:StdRegProv"

Set objReg=GetObject(stdRegPro)

objReg.EnumKey HKEY_LOCAL_MACHINE, uninstallRegKey, arrSubKeys
MsgBox arrSubKeys

  End Function

</script>


Any help appreciated.

Thanks,
Lok..
Posted

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900