Using checkboxes - Advanced Installer Community

We’re moving our forums to a new platform.

You can still browse and search existing topics, but you can no longer create new topics or post replies.

For questions, technical issues, or feature requests, please don’t hesitate to contact our support team at support@advancedinstaller.com.

Thank you for your understanding!

mtande
Posts: 8
Joined: Fri Feb 02, 2007 1:12 pm
Contact: Website

Using checkboxes

I have problems understanding how to set property-based default values for checkboxes in a custom dialog, and how to retrieve the settings later on in the process. I'm sure there is a well-known and easy way to do this, but I am not able to find it.

My custom dialog presents three checkboxes to the user. I need to be able to define as a parameter to AI and/or as a predefined property what the default settings are (checked or uncheked), and I need to pick up the values later on. I've tried many different approaches, but frequently I discover that the checkboxes cannot be modified, or the defaults are set to "always on".

Is there a simple guide to "how to operate checkboxes in a custom dialog" somewhere?

-mats
gigi
Posts: 2103
Joined: Tue Apr 11, 2006 9:55 am
Contact: Website

Hi,

Each check box control has a property associated. When the value of this property is equal with the value you entered in the check box properties list it means that the box is checked.

Here is a simple test:

Create a "ScriptInLine" custom action under "UI Custom Actions" section. Use following code in the "Script Text" field:

Code: Select all

MsgBox "The Box is checked..."
Now select the "Next" button under the dialog that contains the check box control and add following published event:
Name: DoAction
Argument: ScriptInLine
Condition: BOX_PROP = "1" (BOX_PROP the property of the check box and "1" its value)

Hope this helps.

Regards,
Gigi
______________
Gheorghe Rada
Advanced Installer Team
http://www.advancedinstaller.com

Return to “Common Problems”