Innovate or Go Home

Naveen Ajmal, Mohammed
posts - 2, comments - 7, trackbacks - 1

My Links

News

Article Categories

Archives

.Net Community Sites

WIX - Dialogs with Radio Buttons

Creating dialog box controls with Radio Buttons would allow the user to make choices during the installation and could be used to control the flow or the behaviour. Here is a sample code snippet to render radio buttons in WIX. It uses the RadioButtonGroup and the RadioButton element  from the WIX schema.

<Control Id="RadioButtonGroupID" Type="RadioButtonGroup" X="30" Y="94" Width="305" Height="100" Property=" VARIABLETOSTORESTATE " Text="This is My Group">

<RadioButtonGroup Property="VARIABLETOSTORESTATE">

<RadioButton Value="1" X="0" Y="0" Width="200" Height="10" Text="State 1" />

<RadioButton Value="2" X="0" Y="20" Width="200" Height="10" Text="State 2" />

      </RadioButtonGroup>

</Control>

Print | posted on Monday, January 05, 2009 4:47 AM |

Feedback

Gravatar

# re: WIX - Dialogs with Radio Buttons

How can I put a control type text to description each RadioButton ?
In the example above, there are State1 and State2 but I would like a short description box ?
Thanks in advance.
11/24/2009 7:15 AM | Sandjey
Gravatar

# re: WIX - Dialogs with Radio Buttons

Thanks, great tip!
5/18/2011 7:42 AM | Stefan
Gravatar

# re: WIX - Dialogs with Radio Buttons

a melhor radio que ja foi criada vem curti o SOM
7/24/2011 12:07 PM | habbolanche
Gravatar

# re: WIX - Dialogs with Radio Buttons

Please note that property must be global:
1. Lowercase letters
2. Secure=yes


9/28/2011 5:17 AM | drweb86
Gravatar

# re: WIX - Dialogs with Radio Buttons

Property must be upper case and declared with Secure="yes"
9/28/2011 5:21 AM | drweb86
Gravatar

# re: WIX - Dialogs with Radio Buttons

Thought I'd post a sample dialog for convenience:

<Property Id="INSTALLTYPE" Secure="yes" Value="1"></Property>
<Dialog Id="ChooseModeDlg" Width="370" Height="270" Title="[ProductName] [Setup]" NoMinimize="yes">
<Control Id="RadioButtonGroupID" Type="RadioButtonGroup" X="30" Y="94" Width="305" Height="100" Property="INSTALLTYPE">
<RadioButtonGroup Property="INSTALLTYPE">
<RadioButton Value="1" X="0" Y="0" Width="200" Height="10" Text="Type 1" />
<RadioButton Value="2" X="0" Y="20" Width="200" Height="10" Text="Type 2" />
<RadioButton Value="3" X="0" Y="40" Width="200" Height="10" Text="Type 3" />
<RadioButton Value="4" X="0" Y="60" Width="200" Height="10" Text="Type 4" />
</RadioButtonGroup>
</Control>
<Control Id="Back" Type="PushButton" X="180" Y="243" Width="56" Height="17" Text="&amp;Back">
<Publish Event="NewDialog" Value="WelcomeDlg">1</Publish>
</Control>
<Control Id="Next" Type="PushButton" X="236" Y="243" Width="56" Height="17" Default="yes" Text="&amp;Next">
<!--Do something here with the button value maybe...-->
<Publish Event="NewDialog" Value="CustomizeDlg"></Publish>
</Control>
<Control Id="Cancel" Type="PushButton" X="304" Y="243" Width="56" Height="17" Cancel="yes" Text="Cancel">
<Publish Event="SpawnDialog" Value="CancelDlg">1</Publish>
</Control>
<Control Id="BannerBitmap" Type="Bitmap" X="0" Y="0" Width="370" Height="44" TabSkip="no" Text="WixUI_Bmp_Banner" />
<Control Id="Description" Type="Text" X="25" Y="23" Width="280" Height="15" Transparent="yes" NoPrefix="yes">
<Text>Please choose installation type:</Text>
</Control>
<Control Id="BottomLine" Type="Line" X="0" Y="234" Width="370" Height="0" />
<Control Id="Title" Type="Text" X="15" Y="6" Width="200" Height="15" Transparent="yes" NoPrefix="yes">
<Text>{\WixUI_Font_Title}Installation Type</Text>
</Control>
<Control Id="BannerLine" Type="Line" X="0" Y="44" Width="370" Height="0" />
</Dialog>
1/27/2012 2:36 PM | zenmaster
Post A Comment
Title:
Name:
Email:
Website:
Comment:
Verification:
 
 

Powered by: