1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24
|
[Registry]
Root: HKLM; Subkey: "SOFTWARE\MaClé"; Flags: uninsdeletekey
Root: HKLM; Subkey: "SOFTWARE\MaClé"; ValueType: string; ValueName: "path"; ValueData: "{app}"; Check: DoWritePath
[Code]
function InitializeSetup(): Boolean;
begin
if RegKeyExists(HKEY_LOCAL_MACHINE,'SOFTWARE\MaClé') = true then
begin
Msgbox('Clé présente',mbConfirmation,MB_OK);
Result:=true;
//Mettre fin à l'installation
end
else
begin
Msgbox('Clé absente',mbConfirmation,MB_OK);
//Créer la clé
begin
function DoWritePath :boolean;
Result :=true;
end;
end;
end; |
Partager