| | |
Inno Setup Questions
![]() |
•
•
Join Date: Aug 2008
Posts: 19
Reputation:
Solved Threads: 0
I'm creating an installation program using Inno Setup and I have all the custom install pages made but I need to know how to set whether or not a component will be installed. Normally there's a premade page which allows the user to select which components will get installed and which won't but I want to create a custom page with radio buttons for component1, component2 and both. I already know how to check whether a radio button is checked, I just need to know if there's any code that I can use to set the component to be installed. Too confusing?
It'd be like this:
as the bare basics.
It'd be like this:
Pascal and Delphi Syntax (Toggle Plain Text)
if component1.checked = true then component1.install = true; else if component 2.checked = true then component2.install = true; end;
as the bare basics.
I don't know how you have your script set up, but the [Tasks] and [Components] sections are specifically designed for this. Every "task" you list in the tasks section indicates some component to install.
The Inno Setup Help documentation is very complete, and gives examples. You have to stare at it a little while, but it is actually pretty simple. Read the section on installation order to see where stuff fits in. Understanding that section is the key to understanding how to modify the script.
If you must do it in code, take a look through the event and support functions. (It is worth your time to read the entire Pascal Scripting section though.)
Hope this helps.
The Inno Setup Help documentation is very complete, and gives examples. You have to stare at it a little while, but it is actually pretty simple. Read the section on installation order to see where stuff fits in. Understanding that section is the key to understanding how to modify the script.
If you must do it in code, take a look through the event and support functions. (It is worth your time to read the entire Pascal Scripting section though.)
Hope this helps.
•
•
Join Date: Nov 2008
Posts: 1
Reputation:
Solved Threads: 0
; Example
[Components]
Name: "Custom"; Description: "Custom Installation"
; Chose beetwen Applicaton 1 or 2, Components tree shows radio buttons
Name: "Custom\App1"; Description: "Application 1"; Flags: exclusive
Name: "Custom\App2"; Description: "Application 2"; Flags: exclusive
[Files]
Source: "C:\files\app1.exe"; DestDir: "{tmp}"; Components: Custom\App1
Source: "C:\files\app2.exe"; DestDir: "{tmp}"; Components: Custom\App2
....
; I have another problem, when installing multiple components, setup installer unpacks to temp and executing programs , but progress bar shows 100%, how can i solve this
[Components]
Name: "Custom"; Description: "Custom Installation"
; Chose beetwen Applicaton 1 or 2, Components tree shows radio buttons
Name: "Custom\App1"; Description: "Application 1"; Flags: exclusive
Name: "Custom\App2"; Description: "Application 2"; Flags: exclusive
[Files]
Source: "C:\files\app1.exe"; DestDir: "{tmp}"; Components: Custom\App1
Source: "C:\files\app2.exe"; DestDir: "{tmp}"; Components: Custom\App2
....
; I have another problem, when installing multiple components, setup installer unpacks to temp and executing programs , but progress bar shows 100%, how can i solve this
![]() |
Other Threads in the Pascal and Delphi Forum
- Previous Thread: Get Data From Intranet
- Next Thread: Delphi - how to get data from the web
| Thread Tools | Search this Thread |






