0
我想在我的NSIS安裝腳本中安裝VC++ Redist 2008。我得到了下面的一段腳本來做到這一點:以靜默模式安裝VC++ Redist 2008
; Test if Visual Studio Redistributables 2005+ SP1 installed
; Returns -1 if there is no VC redistributables intstalled
Function CheckVCRedist
Push $R0
ClearErrors
ReadRegDword $R0 HKLM "SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\{7299052b-02a4-4627-81f2-1818da5d550d}" "Version"
; if VS 2005+ redist SP1 not installed, install it
IfErrors 0 VSRedistInstalled
StrCpy $R0 "-1"
VSRedistInstalled:
Exch $R0
FunctionEnd
基本上它VC++ 2005年的Redist,但我已經編輯了reg設定查看2008年的存在(是否確定要這麼做?)。我需要一段腳本/命令來安裝VC++ Redist 2008.
- 我在哪裏存儲VC設置以及如何在靜默模式下執行。
- 可以檢查
.onInit
嗎?
有人請給出一個完整的腳本,檢查是否存在以及如何在靜默模式下執行它。
感謝,