2013-01-09 24 views

答えて

5

[RUN]セクションはparametersで、標準またはカスタムChecksとすることができます。 priopriateの設定を忘れないでくださいFlags - waituntilterminatedインストーラスクリプトは、起動されたアクションが終了して次のランチャが起動するまで待機します。

例:

[Files] 
Source: "C:\MyInstallers\*"; DestDir: "{tmp}"; 
Flags: createallsubdirs recursesubdirs deleteafterinstall ignoreversion uninsremovereadonly 

[Run] 
Filename: "{tmp}\dotnetfx35.exe"; Parameters: "/q"; 
Flags: waituntilterminated skipifdoesntexist; 
StatusMsg: "Instalacja bibliotek Microsoft .NET Framework 3.5 SP1..."; 
OnlyBelowVersion: 0,6.2.8400; Check: NET35 

Filename: "{tmp}\vcredist_x86.exe"; Parameters: "/Q"; 
Flags: waituntilterminated skipifdoesntexist; 
StatusMsg: "Instalacja bibliotek Microsoft Visual C++ 2008 (x86)..."; 
Check: not Is64BitInstallMode 

Filename: "{tmp}\vcredist_x64.exe"; Parameters: "/Q"; 
Flags: waituntilterminated skipifdoesntexist; 
StatusMsg: "Instalacja bibliotek Microsoft Visual C++ 2008 (x64)..."; 
Check: Is64BitInstallMode 

Filename: "{tmp}\directx\DXSETUP.exe"; Parameters: "/silent"; 
Flags: waituntilterminated skipifdoesntexist; 
StatusMsg: "Instalacja bibliotek Microsoft DirectX..." 

Filename: "{app}\{#MyAppExeName}"; WorkingDir: "{app}\"; 
Flags: nowait postinstall runascurrentuser skipifsilent; 
Description: "{cm:LaunchProgram,{#StringChange(MyAppName, '&', '&&')}}" 
+0

感謝をsqltoolsのインストールを開始ここで

短い例で、。このスクリプトはInnoスクリプトのようです。 EXEを追加してtempディレクトリにドロップする方法を教えてください。私はInnoと仕事をしたことがありません。 –

+0

'[Files]'セクションを追加しました。 '{tmp}'にコピーするファイルを指すだけです。インストールプロセスが完了すると、インストーラの '{tmp} 'にあるすべてのファイルが削除されます。 C:\ MyInstallersには、 '[実行]'セクション(SubfolderのDirectX)で呼び出したい追加のインストーラがあります。 – RobeN

2

NSIS:

Section 
InitPluginsDir ; $pluginsdir is a folder in %temp%, it is deleted for you when the installer ends 
SetOutPath $PluginsDir 

File "child1.exe" 
ExecWait '"$PluginsDir\child1.exe" /foo "/bar" /baz' 
Delete "$PluginsDir\child1.exe" ; Optional, might be a good idea if the file is large... 

File "child2.exe" 
ExecWait '"$PluginsDir\child2.exe"' 

SetOutPath $Temp ; Don't lock $PluginsDir 
SectionEnd 
+0

ありがとうございました! –

0

innosetupにすることもできますShellExec-機能を持つ別のインストール。これで、もしそれが正面にあるべきかどうか、そしてメインインストールがこのサブインストールが終了するまで待つべきかを定義することができます。私はコード・セクションにあなたの答えのための

if ShellExec('',INSTALL_FOLDER + '\FPS\contributed\sqlncli_x64.msi', '' ,'',SW_HIDE,ewWaitUntilTerminated,ResultCode) then 
    begin 
     Log('executed sql native client with result code ' + IntToStr(ResultCode) + ' this means ' + SysErrorMessage(ResultCode)); 
    end 
    else 
    begin 
     showError(CustomMessage('SQLNATIVE_CLIENT_ABORTED') + SysErrorMessage(ResultCode)); 
    end; 
関連する問題