You may want to place some error checking into this code. Also, you have two operations in the registry, but you do not state which one actually does not perform as you expect. Finally, the code you posted is incomplete, the first if is unmatched and does not have its "else" and "end". Please put a little more effort into your post if you want help.
Ulrich
Announcement
Collapse
No announcement yet.
registry query does not work
Collapse
X
-
registry query does not work
Hello,
I'm trying to create a query on the registry which unfortunately does not work for whatever reason!
Maybe one of you is too kind and corrects my order?
result = Registry.SetValue(HKEY_LOCAL_MACHINE, "Software\\myProgram", "ProductVersion", "ProgramName 2018", REG_SZ);
if result == false then
local sInstallLanguage = Registry.GetValue(HKEY_LOCAL_MACHINE, "System\\CurrentControlSet\\Control\\Nls\\Language ", "InstallLanguage");
if (sInstallLanguage == "0407")then
Dialog.TimedMessage("", "my Text Deutsch", 20000, MB_ICONINFORMATION);
Application.Exit(0);
else
Dialog.TimedMessage("", "my Text Englisch", 20000, MB_ICONINFORMATION);
Application.Exit(0);Tags: None
Leave a comment: