HEScript write to registry not working


Hey I am looking for a bit of help with an issue I am having. I am trying to write to the registry to get an exe I create to run when Windows starts. The problem is it is not writing to the registry. I get no error messages, nothing happens. The test machine is Windows 10 64 bit. I am starting the exe with elevated rights and the exe asks permission to run as admin when it starts. Not sure what is wrong…

. The HEScript I am using to write to the registry is here:

procedure StartupWithWindowsOn;
EbookPath, MyFolder: String;
EbookPath := GetGlobalVar(“HEPublicationPath”, “”);
MyFolder := EbookPath + “software.exe”;
WriteRegStr(5, “SOFTWARE\Microsoft\Windows\CurrentVersion\Run”, “MYPROGIEOOSTART”, MyFolder);

I am calling the HE Script in a php file as follows (note: the script runs then redirects, there is no client side interaction ie. click or anything):



EXE files made with ExeOutput are 32-bit so they will write to the HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\ key and not to the 64-bit key you mentioned.
That could explain your problem.