2014-07-04 92 views
7

如何在Inno安裝程序中靜默安裝Microsoft VC++可再分發包?我使用了下面的代碼,大部分安裝部分都是安靜的,除了安裝進度窗口。如何在Inno安裝程序中靜默安裝Microsoft VC++可再分發包?

這裏是我的[Run]部分的代碼: -

[Run] 
Filename: "{app}\bin\vcredist_x86.exe"; \ 
    Parameters: "/passive /verysilent /norestart /q:a /c:""VCREDI~3.EXE /q:a /c:""""msiexec /i vcredist.msi /qn"""" """; \ 
    Check: VCRedistNeedsInstall; WorkingDir: {app}\bin;Flags: runminimized nowait; \ 
    StatusMsg: Installing CRT... 
+0

什麼問題你面對? – Pratham

+0

@Pratham我想靜靜地安裝Microsoft VC++可再分發程序。但它仍然顯示安裝窗口。 – Myanju

+0

哪個版本的VC++是它?您需要的命令對於不同的版本稍有不同。 – Miral

回答

4

您可以添加那些安裝腳本:

[Files] 
Source: "vcredist_x86.exe"; DestDir: {tmp}; Flags: deleteafterinstall 

[Run] 
Filename: {tmp}\vcredist_x86.exe; \ 
    Parameters: "/q /passive /Q:a /c:""msiexec /q /i vcredist.msi"""; \ 
    StatusMsg: "Installing VC++ 2008 Redistributables..." 

注意是t他運行,如果您使用的是不同版本的可再發行自2008年

+0

你可以告訴我的c + + 2005年?參數是什麼? – Kushal

+0

@Kushal從微軟網站這篇文章可能會幫助你:https://blogs.msdn.microsoft.com/astebner/2007/02/07/update-regarding-silent-install-of-the-vc-8-0 -runtime-vcredist,包/ – Thunder

0

這裏是我的解決方案,參數會略有變化:

Filename: "{tmp}\vc_redist.x86.exe"; Parameters: "/q /norestart"; \ 
    Check: VCRedistNeedsInstall; StatusMsg: "Installing VC++ redistributables..." 
相關問題