Install DirectX & VCRedist in freearc default scri

2019-04-13 23:32发布

问题:

I want to make a iss script by editing 'Inno Setup Free Arc' default script (script link descripted below)

Script Link Here.

Setup will contain:-

  1. Redist directory (contain DXWebSetup.exe,VCRedist.exe)

  2. Setup.exe

  3. data1.bin (data1.arc file name changed to data1.bin)

  4. data2.bin (data2.arc file name changed to data2.bin)

I want to make the script like this:-

  1. Setup will start by user > Buton 'Next'.

  2. Browse directory option (user may browse) > Buton 'Next'.

  3. DirectX & VCRedist checkbox (user will select) > Buton 'Next'.

  4. Confirmation before install > Buton 'Install'.

  5. Installing (extracting freearc archive) > Progress Bar is progressing.

  6. When progress bar will full (after extracting freearc archive) it (progress bar) will paused & DirectX or VCRedist or both will be started one by one as user select.

  7. Installation finish > Buton 'Finish'.

How can i edit this script?

PLEASE TELL ME THE EDITED PART OF THIS SCRIPT...

回答1:

What u asked in your question most part will be done by default freearc script.

If u want 'vcredist' and 'directX' checkbox in components/task page u can simply add the entry to script.

If u want 'vcredist' and 'directX' checkbox in Components page u can add those entry like this:

[Components]
Name: Directx; Description: Install DirectX; Types: custom
Name: Visualc; Description: Install Visual C++; Types: custom

If u don't want to show the combobox in components page then add this :

[Types]
Name: custom; Description: custom; Flags: iscustom

NOTE: Look at the Types: custom in [Components],if u want to show the combox then remove iscustom flag from [Types] section.

If u want 'vcredist' and 'directX' checkbox in Task page u can add those entry like this:

[Tasks]
Name: Directx; Description: Install DirectX; Flags: unchecked
Name: Visualc; Description: Install Visual C++; Flags: unchecked

Now To link those Components/Tasks to [Run] u have to add those to [Run] section like this:

If u choose Components page then :

[Run]
Filename: {src}\Redist\VCRedist.exe; StatusMsg: Installing Visual C++...; Components: Visualc
Filename: {src}\Redist\DXWebSetup.exe; StatusMsg: Installing DirectX...; Components: Directx

If u choose Tasks page then :

[Run]
Filename: {src}\Redist\VCRedist.exe; StatusMsg: Installing Visual C++...; Tasks: Visualc
Filename: {src}\Redist\DXWebSetup.exe; StatusMsg: Installing DirectX...; Tasks: Directx

Now just put 'VCRedist.exe' and 'DXWebSetup.exe' inside "Redist" folder in your output directory({src} means output directory).

Other parts_(Next Button,browse,install etc)_ of your question will be done automatically by default freearc script.



标签: inno-setup