installation - InnoSetup 中的文件选择

标签 installation inno-setup pascal

我希望用户在安装过程中选择许可证文件,如何创建这种对话框?谁能展示一些示例代码吗?

最佳答案

Inno Setup 文档中有一个代码示例(请参阅“Pascal Scripting”、“支持函数引用”、“对话框函数” - 您可以启动here):

var
  FileName: string;
begin
  // Set the initial filename
  FileName := '';
  if GetOpenFileName('', FileName, '', 
     'Text Documents (*.txt)|*.txt|All Files|*.*', 'txt') then
  begin
    // Successful; user clicked OK
    // Filename contains the selected filename
  end;
end;

关于installation - InnoSetup 中的文件选择,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/19575109/

相关文章:

windows - 根据复选框答案有条件地添加注册表项

macos - 将 PackageMaker 命令行构建安装程序移植到 pkgbuild

inno-setup - [Run] 部分是否在触发 ssPostInstall 步骤的 CurStepChanged 事件之前处理?

macros - Pascal 中是否有相当于 C 的 __LINE__ 宏?

windows - 我们如何在delphi中获取键盘空闲时间

perl - 如何在 Windows 8 上安装 Perl?

python - 导入错误: No module named . ..在spyder安装后

maven - JavaFX 8 - 如何使用 Maven 和 INNO 构建 EXE

windows - GetWindowsVersionEx 函数在 Windows 2012 R2 中输出错误

delphi - PChar UTF-8是否已编码?