Old 20th June 2011, 16:13   #1
Samutz
Junior Member
 
Join Date: Feb 2005
Posts: 6
DeleteRegValue not working

I have a very simple script that needs to delete some registry values. These are all values I created manually via administrator account, with the default permissions. The installer isn't removing them though, and I don't know why. I have checked the spelling several times over and confirmed that they do exist and that they are values, not keys.

code:

Section
DetailPrint "Renabling Passive Zenworks Login..."
DeleteRegValue HKLM "Software\Novell\ZCM\ZenLgn" "DisablePassiveModeLogin"
DeleteRegValue HKLM "Software\Novell\ZCM\ZenLgn" "DisablePassiveModeLoginPrompt"

DetailPrint "Disabling Administrator Auto Login..."
DeleteRegValue HKLM "Software\Microsoft\Windows NT\CurrentVersion\Winlogon" "DefaultUserName"
DeleteRegValue HKLM "Software\Microsoft\Windows NT\CurrentVersion\Winlogon" "DefaultPassword"
DeleteRegValue HKLM "Software\Microsoft\Windows NT\CurrentVersion\Winlogon" "AutoAdminLogon"
SectionEnd

Samutz is offline   Reply With Quote
Old 20th June 2011, 16:42   #2
Afrow UK
Moderator
 
Afrow UK's Avatar
 
Join Date: Nov 2002
Location: Surrey, England
Posts: 8,434
x64? SetRegView 64.

Edit: Also, are you running as an administrator? Use RequestExecutionLevel admin (and check the user is an admin in .onInit using UserInfo).

Stu
Afrow UK is offline   Reply With Quote
Old 20th June 2011, 17:18   #3
Samutz
Junior Member
 
Join Date: Feb 2005
Posts: 6
It was SetRegView 64. Thanks.
This is the first installer I've written for a x64 system and the 32/64 difference didn't occur to me.

RequestExecutionLevel admin was already set.
Samutz is offline   Reply With Quote
Reply
Go Back   Winamp & Shoutcast Forums > Developer Center > NSIS Discussion

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump