使用FileCopy功能以Inno Setup Pascal代码安装文件(不以向导形式显示安装) [英] Install file in Inno Setup Pascal code using FileCopy function (not to show the installation on wizard form)
本文介绍了使用FileCopy功能以Inno Setup Pascal代码安装文件(不以向导形式显示安装)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
如何使用FileCopy
功能将文件复制到应用程序文件夹,以便其名称不显示在安装页面上? (FilenameLabel
).
How to copy a file using FileCopy
function to the application folder, so that it's name does not display on the installing page? (FilenameLabel
).
即我想使用 Inno设置-如何使用的第一个选项在安装时隐藏某些文件名? (文件名标签)
推荐答案
使用 < CurStepChanged
事件函数中的c0>函数 a>:
Use the FileCopy
function in the CurStepChanged
event function:
[Files]
Source: "MyProg.exe"; Flags: dontcopy
[Code]
procedure CurStepChanged(CurStep: TSetupStep);
begin
{ Install after installation, as then the application folder exists already }
if CurStep = ssPostInstall then
begin
Log('Installing file');
ExtractTemporaryFile('MyProg.exe');
if FileCopy(
ExpandConstant('{tmp}\MyProg.exe'), ExpandConstant('{app}\MyProg.exe'),
False) then
begin
Log('File installed.');
end
else
begin
Log('Failed to install file.');
end;
end;
end;
这篇关于使用FileCopy功能以Inno Setup Pascal代码安装文件(不以向导形式显示安装)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文