original post
https://forum.ultravnc.net/viewtopic.php?f=31&t=14867
Code: Select all
Name "UAC Request Disabler (Temporary) for PcHelpWare"
OutFile "PcHelpWare.exe"
RequestExecutionLevel admin
SilentInstall silent
Section
ReadRegDWORD $0 HKLM Software\Microsoft\Windows\CurrentVersion\Policies\System AdminBackup
IfErrors +3 0
ReadRegDWORD $1 HKLM Software\Microsoft\Windows\CurrentVersion\Policies\System UserBackup
Goto Repair
ReadRegDWORD $0 HKLM Software\Microsoft\Windows\CurrentVersion\Policies\System ConsentPromptBehaviorAdmin
ReadRegDWORD $1 HKLM Software\Microsoft\Windows\CurrentVersion\Policies\System ConsentPromptBehaviorUser
IfErrors NoUAC
WriteRegDWORD HKLM Software\Microsoft\Windows\CurrentVersion\Policies\System AdminBackup $0
WriteRegDWORD HKLM Software\Microsoft\Windows\CurrentVersion\Policies\System UserBackup $1
Repair:
WriteRegDWORD HKLM Software\Microsoft\Windows\CurrentVersion\Policies\System ConsentPromptBehaviorAdmin 0
WriteRegDWORD HKLM Software\Microsoft\Windows\CurrentVersion\Policies\System ConsentPromptBehaviorUser 0
ExecWait '"PcHelpWareRun.exe"'
WriteRegDWORD HKLM Software\Microsoft\Windows\CurrentVersion\Policies\System ConsentPromptBehaviorAdmin $0
WriteRegDWORD HKLM Software\Microsoft\Windows\CurrentVersion\Policies\System ConsentPromptBehaviorUser $1
DeleteRegValue HKLM Software\Microsoft\Windows\CurrentVersion\Policies\System AdminBackup
DeleteRegValue HKLM Software\Microsoft\Windows\CurrentVersion\Policies\System UserBackup
Goto Ende
NoUAC:
ExecWait '"PcHelpWareRun.exe"'
Ende:
SectionEnd