uses Registry;
function NebenUhr(txt: string): boolean;
var
Reg: TRegistry;
begin
result := false;
Reg := TRegistry.Create;
try
Reg.RootKey := HKEY_CURRENT_USER;
if Reg.OpenKey('\Control Panel\International\', True) then begin
Reg.writestring('s1159', txt);
Reg.writestring('s2359', txt);
Reg.writestring('sShortDate', 'd.M.yyyy');
Reg.writestring('sTimeformat', 'HH:mm:ss:tt');
result := true;
end;
finally
Reg.CloseKey;
Reg.Free;
end;
end;
// Beispielaufruf
procedure TForm1.Button12Click(Sender: TObject);
begin
if not
NebenUhr(' DBR.Software')
then showmessage('FEHLER')
else showmessage('Bitte Rechner neu starten!')
end;