Jump to content
Sign in to follow this  
mdwerne

RegDelete HKLM64

Recommended Posts

mdwerne

I have searched the forums and found some very old topics on this,

http://www.autoitscript.com/forum/index.ph...st&p=381583

http://www.autoitscript.com/forum/index.ph...st&p=341823

none seem to work. ^_^

I can write to a 64bit OS registry all day long:

$RegVar = "HKLM\SOFTWARE\Microsoft\Active Setup\Installed Components"
$RegVar64 = "HKLM64\SOFTWARE\Microsoft\Active Setup\Installed Components"

If @OSArch = "X86" Then
    RegWrite($RegVar & "\{007A429C-B690-4FA7-9AC8-0DF764C19AEB}")
    RegWrite($RegVar & "\{007A429C-B690-4FA7-9AC8-0DF764C19AEB}", "", "REG_SZ", "Betatest")
    RegWrite($RegVar & "\{007A429C-B690-4FA7-9AC8-0DF764C19AEB}", "DateOfTest", "REG_SZ", $Date)
ElseIf @OSArch = "X64" Then
    RegWrite($RegVar64 & "\{007A429C-B690-4FA7-9AC8-0DF764C19AEB}")
    RegWrite($RegVar64 & "\{007A429C-B690-4FA7-9AC8-0DF764C19AEB}", "", "REG_SZ", "Betatest")
    RegWrite($RegVar64 & "\{007A429C-B690-4FA7-9AC8-0DF764C19AEB}", "DateOfTest", "REG_SZ", $Date)
Else
MsgBox(32, "Error", "Cannot determine the OS Architecture, exiting!")
EndIfoÝ÷ ح§"Úòjw]zW­zØZ¶Æ¦zG²jëh×6$RegVar = "HKLM\SOFTWARE\Microsoft\Active Setup\Installed Components"
$RegVar64 = "HKLM64\SOFTWARE\Microsoft\Active Setup\Installed Components"

If @OSArch = "X86" Then
    RegDelete($RegVar & "\{007A429C-B690-4FA7-9AC8-0DF764C19AEB}")
ElseIf @OSArch = "X64" Then
    RegDelete($RegVar64 & "\{007A429C-B690-4FA7-9AC8-0DF764C19AEB}")
Else
MsgBox(32, "Error", "Cannot determine the OS Architecture, exiting!")
EndIf

32bit works just fine, 64bit I get bupkis.

Any thoughts?

Thanks,

-Mike

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.