September 9, 2011

Using Radio button in InstallShield – Simplified

This article explains about adding two Radio buttons to a Radio group and setting / reading the option's value in a VBScript Custom Action.
[Note: The steps are based on Basic MSI Project using InstallShield 2011].
·         Create a Radio Group in a Custom dialog and name the property as RADIOGROUPVAR.
·         Add two radio buttons (with text Yes & No) to the Radio Group and define ‘order’ & ‘value’ properties of the radio button as detailed below

Radio Button
Order
Value
Yes
2
Yes
No
1
No

In this example, Order is set to 1 for ‘No’ radio button and hence it will be selected by default.
·         Further set the value of ‘RADIOGROUPVAR’ in Property Manager as No, to ensure that ‘No’ radio button is selected by default.
So now the UI Design is done.
·         Set / Read the radio button value through VB Script Custom Action
o   Set
Session.Property(“RADIOGROUPVAR”)=”No”
o   Read
MSGBOX “RADIOGROUPVAR Value =>“  &  Session.Property(“RADIOGROUPVAR”)

No comments:

Post a Comment