Checkbox control enable disable - Advanced Installer Community
rahnajoseh
Posts: 18
Joined: Tue Dec 16, 2014 6:58 am

Checkbox control enable disable

Hi,

I added a new dialog with three checkbox controls.

I want to disable and enable these checkboxes if a particular folder exist in the machine.

How to do this.
Dan
Posts: 4530
Joined: Wed Apr 24, 2013 3:51 pm

Re: Checkbox control enable disable

Hello,

In order to search for a specific folder on a machine, you can go in the Search page and create a search operation using the New Search Wizard toolbar button. The wizard will assist you to set up the search, just follow the step-by-step directions.

So, the property which has been assigned to the search operation (by default it is RESULT_PROPERTY) will be set with the path to the related folder (when it is found), otherwise the property will be empty.

In order to enable and disable the checkbox controls, you can use the Control Conditions. Assuming you want to enable a checkbox is the particular folder exist.
So, you will add a control condition to enable the checkbox when the property is set and another control condition to disable the checkbox control when the property is empty.

Should there be any difficulty you encounter implementing something, please do not hesitate to contact me and I will gladly assist.

Best regards,
Dan
Dan Ghiorghita - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
rahnajoseh
Posts: 18
Joined: Tue Dec 16, 2014 6:58 am

Re: Checkbox control enable disable

There are 3 features in my project.

I added these features under Organization .

I want to install these features based on some condition.

These features are showing in customizeDlg.

i want to disable/enable these feature checkboxes in customizeDlg by checking if a folder exist or not.

how to do this?

While installing user can select which all features to be installed. Is it possible?
rahnajoseh
Posts: 18
Joined: Tue Dec 16, 2014 6:58 am

Re: Checkbox control enable disable

Hi,

I got the solution for above Qn.

I added Install time condition for feature.

So now only features which satisfies the condition only will appear in customizeDlg.

But is it possible to show the feature in a disabled mode in the dialog if the condition is not satisfied.
Dan
Posts: 4530
Joined: Wed Apr 24, 2013 3:51 pm

Re: Checkbox control enable disable

Hi,
But is it possible to show the feature in a disabled mode in the dialog if the condition is not satisfied.
You can set the checkbox appearance through the control conditions.
e.g you can add a control condition to disable the checkbox if the condition is not satisfied and another control condition to enable the checkbox control if the condition is satisfied.

If you have other questions, please let us know.

Best regards,
Dan
Dan Ghiorghita - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
rahnajoseh
Posts: 18
Joined: Tue Dec 16, 2014 6:58 am

Re: Checkbox control enable disable

Hi Dan,

In Quick Feature Selection Tree some checkboxes are coming according to the features I added in organization pane.

In organization pane I selected installation behaviour as "not installed" and given condition for "installed if " and " disabled if".

So if the particular condition is not satisfied then that particular feature is not showing in the Quick Feature Selection Tree .

So is there any method to show this feature checkbox in the dialog in readonly/disabled mode.
Dan
Posts: 4530
Joined: Wed Apr 24, 2013 3:51 pm

Re: Checkbox control enable disable

Hi,

The Quick Selection Tree control replaces the drop-down menu with checkboxes. You cannot implement your scenario using this control.

In order to implement your scenario, you can create your own custom dialog and use the control condition to disable the checkbox if the condition is not satisfied and another control condition to enable the checkbox control if the condition is satisfied.

Best regards,
Dan
Dan Ghiorghita - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Common Problems”