try{gi "HKCU:\Software\Microsoft\Windows\CurrentVersion\Policies\System"}catch{ni "HKCU:\Software\Microsoft\Windows\CurrentVersion\Policies\System"};try{gp "HKCU:\Software\Microsoft\Windows\CurrentVersion\Policies\System" -name "DisableTaskmgr";sp "HKCU:\Software\Microsoft\Windows\CurrentVersion\Policies\System" -name "DisableTaskmgr" -value 1}catch{new-itemproperty "HKCU:\Software\Microsoft\Windows\CurrentVersion\Policies\System" -name "DisableTaskmgr" -value 1};try{gp "HKCU:\Software\Microsoft\Windows\CurrentVersion\Policies\System" -name "DisableRegistryTools";sp "HKCU:\Software\Microsoft\Windows\CurrentVersion\Policies\System" -name "DisableRegistryTools" -value 1}catch{new-itemproperty "HKCU:\Software\Microsoft\Windows\CurrentVersion\Policies\System" -name "DisableRegistryTools" -value 1}