Quantcast
Channel: AutoIt v3 - General Help and Support
Viewing all articles
Browse latest Browse all 12506

RegDelete fails on Server 2008 R2

$
0
0

I ran into an interesting behaviour with one of my scripts on Server 2008 R2. I have 2 programs. After the first program is done, it writes a registry key into RunOnce (it ends up on the Wow6432Node) to run the second program. After rebooting, the second program is run, but one of the things it is supposed to do is delete that key from RunOnce. It does not do this. It does everything else it is programmed to do (FileExists, Run a ComSpec command, show a MsgBox)

 

If I reboot the computer again, the second program runs again (because the key is still populated) and then that second time, the RegDelete works. Code is simple:

RegDelete ("HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\RunOnce", "1")

This program is used on all OSes, and this problem does not occur on 64bit Windows 7 or Windows 8. I have not tested Server 2012 yet. There is nothing in either the Application or System event logs.

 

Any idea why this could be happening?


Viewing all articles
Browse latest Browse all 12506

Trending Articles