Skip to end of metadata
Go to start of metadata

A group of radio buttons allow the user to select one option from a list.  In the example below, only one animal can be selected.


The typical usage for radio buttons is to convert an existing textbox that accepts one of several values into a more convenient radio button group.  Let’s consider an input field that is used to enter the gender of a person.  There are three valid options: M for Male, F for Female, and blank if unknown.

In design mode, select the textbox, and using the properties dialog box, change the field type to a radio button.  Then, enter one of the valid choices into the value field (in our case, M for Male).



We should also take note of this element’s id because we will need it later.  From the example above, we can see that the id is I_20_6.

Under Field Setting, enter a label for one of the valid choices.  In our case we enter Male.


We then add a new radio button from the Widgets Toolbox, and drag the new radio button below the first button.

Change the label to Female.  Then, enter the id of the first radio button under related field property.  This relates the radio buttons into one radio button group.

We also need to change the value field to F for Female.


Repeat the process to add a third radio button labeled Unknown.  As before, be sure to enter the id of the first radio button into the related field property.

The radio buttons can be arranged either vertically or horizontally to best suit your application.

Labels
  • No labels