Hola,
El problema está en el método "WriteInteger()", que requiere dos parámetros, el primero el nombre del valor a escribir, en este caso "ShowUpdates".
El asunto puede quedar más o menos así:
Código Delphi
[-]
uses
Registry;
function ChangeShowUpdatesRegistryValue(value: integer): boolean;
const
REGISTRY_VALUE = 'ShowUpdates';
REGISTRY_KEY = 'Software\Microsoft\Windows\CurrentVersion\App Management\';
begin
with TRegistry.Create() do
try
RootKey := HKEY_CURRENT_USER;
if OpenKey(REGISTRY_KEY, true) then
begin
if (ReadInteger(REGISTRY_VALUE) <> value) then
WriteInteger(REGISTRY_VALUE, value);
result := true;
end
else
result := false;
finally
Free();
end;
end;