Inno Setup MS Access 2010 静默安装
Inno Setup MS Access 2010 silent install
我想使用 Inno Setup 创建 Access 2010 运行时的安装程序。
当我尝试编译文件时,我从 Inno Setup 收到此错误:
File: xxxx\config.xml
Line 1:
Unrecognized parameter name ""
我已经创建了推荐的 config.xml
文件如下(实际上我只是逐字复制)。
config.xml 文件:
<Configuration Product="AccessRT">
<Display Level="Basic" CompletionNotice="no" SuppressModal="yes" AcceptEula="yes" />
<Setting Id="SETUP_REBOOT" Value="IfNeeded" />
</Configuration>
Inno 安装文件:
#include <idp.iss>
[Files]
Source: C:\Users\john.eggHeadLtd\OneDrive\blueEggShare\config.xml; \
DestDir: {tmp}; Flags: ignoreversion
[Run]
Filename: {tmp}\AccRt.exe /extract:{tmp}\AccRT;
#include "config.xml"
Filename: {tmp}\setup.exe; Parameters: /config {tmp}\config.xml;
Filename: {tmp}\accsp2.exe
[Code]
procedure InitializeWizard();
begin
{ Let's download two zipfiles from my website.. }
idpaddfile('https://download.microsoft.com/download/2/6/0/260AA63A-A275-4A92-950D-CE20B490D0B9/AccessRuntime.exe',expandconstant('{tmp}\accRt.exe'));
idpaddfile('https://download.microsoft.com/download/C/C/2/CC28BC00-1AF0-44B9-8A5D-9D8C8E4899BB/accessrtsp2010-kb2687444-fullfile-x86-en-us.exe',expandconstant('{tmp}\accSp2.exe'));
{ Start the download after the "Ready to install" screen is shown }
idpdownloadafter(wpReady);
end;
首先你需要提取AccessRuntime.exe
(你download/save到{tmp}\accRt.exe
):
[Run]
Filename: {tmp}\accRt.exe; Parameters: /extract:{tmp}\accRt /quiet
然后你必须 运行 使用你的配置文件提取 setup.exe
:
[Files]
Source: C:\source\path\config.xml; DestDir: {tmp}
[Run]
Filename: {tmp}\accRt\setup.exe; Parameters: "/config ""{tmp}\config.xml"""
对我对你的代码的修改的一些评论:
ignoreversion
标志对 .xml 文件没有任何影响
- 您最好将配置文件的路径用引号引起来,以防
{tmp}
包含空格。
我想使用 Inno Setup 创建 Access 2010 运行时的安装程序。
当我尝试编译文件时,我从 Inno Setup 收到此错误:
File: xxxx\config.xml
Line 1:
Unrecognized parameter name ""
我已经创建了推荐的 config.xml
文件如下(实际上我只是逐字复制)。
config.xml 文件:
<Configuration Product="AccessRT">
<Display Level="Basic" CompletionNotice="no" SuppressModal="yes" AcceptEula="yes" />
<Setting Id="SETUP_REBOOT" Value="IfNeeded" />
</Configuration>
Inno 安装文件:
#include <idp.iss>
[Files]
Source: C:\Users\john.eggHeadLtd\OneDrive\blueEggShare\config.xml; \
DestDir: {tmp}; Flags: ignoreversion
[Run]
Filename: {tmp}\AccRt.exe /extract:{tmp}\AccRT;
#include "config.xml"
Filename: {tmp}\setup.exe; Parameters: /config {tmp}\config.xml;
Filename: {tmp}\accsp2.exe
[Code]
procedure InitializeWizard();
begin
{ Let's download two zipfiles from my website.. }
idpaddfile('https://download.microsoft.com/download/2/6/0/260AA63A-A275-4A92-950D-CE20B490D0B9/AccessRuntime.exe',expandconstant('{tmp}\accRt.exe'));
idpaddfile('https://download.microsoft.com/download/C/C/2/CC28BC00-1AF0-44B9-8A5D-9D8C8E4899BB/accessrtsp2010-kb2687444-fullfile-x86-en-us.exe',expandconstant('{tmp}\accSp2.exe'));
{ Start the download after the "Ready to install" screen is shown }
idpdownloadafter(wpReady);
end;
首先你需要提取AccessRuntime.exe
(你download/save到{tmp}\accRt.exe
):
[Run]
Filename: {tmp}\accRt.exe; Parameters: /extract:{tmp}\accRt /quiet
然后你必须 运行 使用你的配置文件提取 setup.exe
:
[Files]
Source: C:\source\path\config.xml; DestDir: {tmp}
[Run]
Filename: {tmp}\accRt\setup.exe; Parameters: "/config ""{tmp}\config.xml"""
对我对你的代码的修改的一些评论:
ignoreversion
标志对 .xml 文件没有任何影响- 您最好将配置文件的路径用引号引起来,以防
{tmp}
包含空格。