I am setting the value of a radio button to a property. For example I set the value of one of the radio buttons in the radio group 'RADIO' to [MYPROPERTY]. When I access this from my vbscript using Session.Property("RADIO"), I get the literal string "[MYPROPERTY]" instead of the the value contained in the property MYPROPERTY. What am I doing wrong here?
I am not sure why you are encountering this behavior. Please send you aip project file ( or a stripped down version that accurately reproduces this behavior) to support at advancedinstaller dot com so we can further investigate this issue.
The behaviour is confusing. When the dialog is first displayed, without me clicking any radio buttons, for the currently selected button the value of the radio button is as specified by me earlier. But when I click on a radio button, then I get the resolved value. I am still playing around to get a defenitive conclusion. I will let you know once I have concluded something.
The behaviour is as I explained earlier. When the dialog box is displayed, if nothing is clicked by the user, eventhough there is a default radio button is selected, the property is not resolved ie the value of radio button is [MYPROPERTY]. But if a radio button is clicked. from then onwards the value starts getting resolved. Any idea why? Also when I click on a radion buton, the radion button does not get selected on the first click (but the previously selected radio button is unselected). I have to click on the radio button for the second time to get it selected.
This seems to be a limitation in Windows Installer. The radio group's property cannot hold a formatted value. In order for a radio group to have a default radio selected, it's property's value needs to be the same as the default radio. Since your default radio's value is a property, and the group's property cannot refer to another property, then no default is selected.
You will have to manually resolve the group property's value. You can achieve this by using an Init Event on the same Dialog as your radio group. Assume your radiogroup's property name is GROUPPROPERTY and the radio button's property is MYPROPERTY. On the dialog's Init Events page, create a SetProperty event with the [GROUPPROPERTY] as the first parameter and [MYPROPERTY] as the second. This will set the value of GROUPPROPERTY to the value of MYPROPERTY, thus selecting the radiobutton as the default.
Note that this will not work with Enhanced UI due to a small bug. We have fixed this and the fix will be available in the next version of Advanced Installer which is due soon. If you need the fix sooner, please send us an email to support at advancedinstaller dot com and we will send you the fix.
I am using the 'Enhanced User Interface'. When I set the value of a radio button to a property the behaviour is as follows when I click on a radio button:
1 The previously selected radio button is unselected
2 The currently clicked radio button is still unselected
3 Value of the RADIO gets updated with the resolved value of the property set to the currently clicked button.
Ultimately I have to click the radio button twice to see it selected. Is this something you already know? If not is this a bug and will it be fixed in future?
I downloaded the latest version of the Advanced Installer. In the website it is 7.3. When I download and install, it is still 7.2.1. Is that the wrong file in place?
FOLLOW US
Get the latest news in Application Packaging