OnClientCheckedChanged
The checkedChanged event is subsequent to the checkedChanging event, and occurs when the RadCheckBox checked state is changed.
The event handler receives two parameters:
-
The instance of the clicked RadCheckBox control.
-
An eventArgs parameter of type Telerik.Web.UI.ButtonCheckedEventArgs, containing the following properties and methods:
-
get_checked() - returns the checked state of the control.
-
get_domEvent() - returns the DOM event of the control.
-
get_commandName() - returns the value assigned to the RadCheckBox's CommandName property.
-
get_commandArgument() - returns the value assigned to the RadCheckBox's CommandArgument property.
-
This event is useful when the user wants to execute custom client code when the button changes its toggle state.
Example 1: Using the OnClientCheckedChanged event to get the checked state of the checkbox.
<script type="text/javascript">
function checkedChanged(sender, args) {
alert(args.get_checked());
}
</script>
<telerik:RadCheckBox ID="RadCheckBox1" runat="server"
AutoPostBack="false" OnClientCheckedChanged="CheckedChanged">
</telerik:RadCheckBox>