Inno Setup Standardeinstellungen für benutzerdefinierte Installationseinstellungen aus einer Datei (.inf) für die unbeaufsichtigte Installation laden

Ich habe ein Setup-Skript, mit dem der Benutzer angeben kann, wo er meine Anwendung installieren möchte. Es ist in Form eines Pascal-Skripts innerhalb des[Code] Block

var
  SelectUsersPage: TInputOptionWizardPage;
  IsUpgrade : Boolean;
  UpgradePage: TOutputMsgWizardPage;

procedure InitializeWizard();
var
  AlreadyInstalledPath: String;
begin
  { Determine if it is an upgrade... }
  { Read from registry to know if this is a fresh install or an upgrade }
  if RegQueryStringValue(HKLM, 'Software\Microsoft\Windows\CurrentVersion\Uninstall\{#MyAppId}_is1', 'Inno Setup: App Path', AlreadyInstalledPath) then
    begin
      { So, this is an upgrade set target directory as installed before }
      WizardForm.DirEdit.Text := AlreadyInstalledPath;
      { and skip SelectUsersPage }
      IsUpgrade := True;

      { Create a page to be viewed instead of Ready To Install }
      UpgradePage := CreateOutputMsgPage(wpReady,
        'Ready To Upgrade', 'Setup is now ready to upgrade {#MyAppName} on your computer.',
        'Click Upgrade to continue, or click Back if you want to review or change any settings.');
    end
  else
    begin
      IsUpgrade:= False;
    end;

  { Create a page to select between "Just Me" or "All Users" }
  SelectUsersPage := CreateInputOptionPage(wpLicense,
    'Select Users', 'For which users do you want to install the application?',
    'Select whether you want to install the library for yourself or for all users of this computer. Click next to continue.',
    True, False);

  { Add items }
  SelectUsersPage.Add('All users');
  SelectUsersPage.Add('Just me');

  { Set initial values (optional) }
  SelectUsersPage.Values[0] := False;
  SelectUsersPage.Values[1] := True;
end;

Die Frage ist also, wie ich eine unbeaufsichtigte Installation unterstützen kann. Wenn ein Benutzer @ aufru/SILENT oder/VERYSILENT Das Installationsprogramm verwendet standardmäßigSelectUsersPage.Values[1], das ist fürJust Me. Ich möchte den Benutzer unterstützen, der das Installationsverzeichnis ändern möchte, indem er eine Antwortdatei bereitstellt.

Ich habe nicht den gesamten Code entwickelt und bin ein Neuling bei Pascal.

Vielen Dank

Antworten auf die Frage(2)

Ihre Antwort auf die Frage