RibbonBarItemRadioButton
Namespace: Wisej.Web.Ext.RibbonBar
Assembly: Wisej.Web.Ext.RibbonBar (4.1.0.0)
Represents a radio button in a RibbonBarGroup.
- C#
- VB.NET
public class RibbonBarItemRadioButton : RibbonBarItem
Public Class RibbonBarItemRadioButton
Inherits RibbonBarItem
All the radio buttons in the same RibbonBarGroup are mutually exclusive.
Constructors
RibbonBarItemRadioButton()
Initializes a new instance of RibbonBarItemRadioButton.
Properties
Checked
Boolean: Returns or sets whether the RibbonBarItemRadioButton is in the checked state. (Default: False)
Value: true if the RibbonBarItemRadioButton is in the checked state; otherwise, false. The default is false.
Changing the value fires the CheckedChanged event. When the user clicks the radio button, the value is updated first, then the Click and ItemClick events are fired. When the user checks a radio button, all the other RibbonBarItemRadioButton items in the same RibbonBarGroup are unchecked, which updates their Checked property and fires their events as well. When the value is set in code, the other radio buttons are unchecked on the client but their Checked property on the server is not changed: uncheck them in code as well.
Example:
Checking a radio button in code and unchecking the others in the same group:
private void SelectView(RibbonBarItemRadioButton selected)
{
foreach (var item in selected.Parent.Items)
{
if (item is RibbonBarItemRadioButton radio)
radio.Checked = (radio == selected);
}
}
Methods
OnCheckedChanged(e)
Fires the CheckedChanged event.
OnWebEvent(e)
Processes the event from the client.
| Parameter | Type | Description |
|---|---|---|
| e | WisejEventArgs | Event arguments. |
OnWebRender(config)
Renders the client component.
| Parameter | Type | Description |
|---|---|---|
| config | Object | Dynamic configuration object. |
Events
CheckedChanged
EventHandler Fired when the value of the Checked property changes.
Implements
| Name | Description |
|---|---|
| IUserData | |
| IWisejComponent | |
| IWisejSerializable |