Regdelete problems

(imported topic written by mcalvi91)

We are creating a fixlet to fix a problem with our windows agent GUIDs. When we try to delete the GUID using the following actionscript, the log shows it as a success, but the reg value stays in the registry.

regdelete "

HKLM\SOFTWARE\Network Associates\ePolicy Orchestrator\Agent

" “AgentGUID”

any help would be appreciated.

(imported comment written by SystemAdmin)

Hi mcalvi,

I don’t think you can use the HKLM shortcut with the regdelete action. Try using the full string ‘HKEY_LOCAL_MACHINE’.

Alternatively, we like to use .reg files to manipulate the registry. They are a little easier to work with most of the time.

delete __appendfile 
delete temp.reg 
 
appendfile REGEDIT4
appendfile [-HKEY_LOCAL_MACHINE\SOFTWARE\Network Associates\ePolicy Orchestrator\Agent\AgentGUID]
 
move __appendfile temp.reg
 
wait regedit -s temp.reg

(imported comment written by mcalvi91)

expanding the HKLM -> HKEY_LOCAL_MACHINE did the trick… thanks!