# RadioButton

The RadioButton control can display text, an `Image`, or both.

When a user selects one RadioButton within a group, the others clear automatically. All RadioButton controls in a given container, such as a `Form`, constitute a group. To create multiple groups on one form, place each group in its own container, such as a `GroupBox` or `Panel` control.

RadioButton and CheckBox controls serve similar functions: they offer choices users can select or clear. The key difference is that multiple CheckBox controls can be selected simultaneously, while RadioButtons are mutually exclusive.

Use the `Checked` property to get or set the state of a RadioButton. The control's appearance can be set to a toggle-style button or standard option button using the `Appearance` property.

{% hint style="info" %}
For a full list of properties, methods and events see the [API documentation.](http://docs.wisej.com/api)
{% endhint %}

## Features

### Selection

When placed into a container, only one RadioButton control can be selected at a time.

![RadioButton control demonstrating mutually exclusive selection](https://553579532-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-MF1D11gPs_az3xaKusw%2Fuploads%2Fgit-blob-ce86c08d0b47cb6ef98def402e247204946da67b%2Fimage.png?alt=media)

{% hint style="info" %}
If the `AutoCheck` property is set to false, more than one radio button might be selected within the container.
{% endhint %}

### Alignment

The RadioButton icon and label can be positioned anywhere in relation to each other using the `CheckAlign` and `TextAlign` properties.

![RadioButton control showing various alignment options](https://553579532-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-MF1D11gPs_az3xaKusw%2Fuploads%2Fgit-blob-0dc04274c31ce5f9a0b9706cad2ee8777c96fb94%2Fimage.png?alt=media)

## Advanced

### JavaScript Widget

| Item             | Description                                                                                                                          |
| ---------------- | ------------------------------------------------------------------------------------------------------------------------------------ |
| Class name       | "wisej.web.RadioButton"                                                                                                              |
| Theme appearance | "radiobutton", see [Themes](https://docs.wisej.com/theme-builder/theme-elements/elements).                                           |
| Child components | "icon" is the radiobutton icon, "label" is the text. See [JavaScript](https://docs.wisej.com/docs/concepts/javascript-object-model). |
| Source code      | [https://github.com/iceteagroup/wisej-js](https://github.com/iceteagroup/wisej-js/blob/master/wisej.web.TextBox.js)                  |
