Reputation: 4094
I am using RadCombobox in Telerik Ajax and what I would like to do is to force users must at least select 1 item, so I try to prevent user to uncheck item when it is the only checked item.
Problem is that when I enable the EnableCheckAllItemsCheckBox
to true, there will be a Check ALL
option by default, and users can first check all items, then uncheck all items, which is what I am trying to prevent.
First I have find this client event:
However it needs Version 2013+, while I am using 2012.1.411, so it does not work out.
Then I found this server event which probably provide same functionality:
http://docs.telerik.com/devtools/aspnet-ajax/controls/combobox/server-side-programming/checkallcheck
Now my problem is, I cannot find this server side event either!
The document did not say which version of the framework needed to use this event, I wonder Is there any reference / document listing what version of the framework support what kind of methods/events of each control?
Upvotes: 0
Views: 1115
Reputation: 1024
I don't know is this what you want....
To get or trigger CheckAll in RadComboBox event in clientside use this...
<asp:ScriptManager ID="sm" runat="server"></asp:ScriptManager>
<telerik:RadComboBox ID="rcb" runat="server" EnableCheckAllItemsCheckBox="true" CheckBoxes="true" OnClientLoad="onChangingInCheckAll">
<Items>
<telerik:RadComboBoxItem Text="a" />
<telerik:RadComboBoxItem Text="b" />
<telerik:RadComboBoxItem Text="c" />
</Items>
</telerik:RadComboBox>
<telerik:RadScriptBlock ID="rsb" runat="server">
<script type="text/javascript">
function onChangingInCheckAll() {
$telerik.$('.rcbCheckAllItems').click(function () {
// Alert Testing
alert('a');
// Do your stuff
});
}
</script>
</telerik:RadScriptBlock>
Upvotes: 2