Inno Setup Execute a batch file before [Files] section

前端 未结 3 690
北恋
北恋 2021-01-04 19:14

Currently my batch file is in [Run] section. I need my batch file to execute before the [Files] section. Is there a way to do this in Inno Setup? Currently the [Run] section

3条回答
  •  遥遥无期
    2021-01-04 19:49

    You can use the InitializeSetup event + some pascal scripting.

    See; How to run a file before setup with Inno Setup

    Not mentioned in that example; to get the file from the installer you would use ExtractTemporaryFile('your.bat') then Exec(ExpandConstant('{tmp}\your.bat ... to run it.

提交回复
热议问题