Hi There
I am using a radcombobox box as below:-
When the user types more than 2 characters we go off and try to bring back results to display and that works just fine - when niothing is found however we see the text No Matches which is great, but what I need to have happen is for focus to leave this rad combobox from the code behind within :-
I am using a radcombobox box as below:-
<telerik:RadComboBox ID="radComboFullname" AllowCustomText="true" runat="server" AutoPostBack="true" SkinID="fullnamesearchdropdown" |
CausesValidation="False" OnClientItemsRequesting="RequestingHandler" EnableLoadOnDemand="true" |
HighlightTemplatedItems="true" ItemRequestTimeout="750" DataSourceID="objDSClientSmartSearch" |
DataTextField="fullname" DataValueField="id" TabIndex="1" OnItemsRequested="radComboFullname_ItemsRequested" |
OnSelectedIndexChanged="radComboFullname_SelectedIndexChanged" |
ShowMoreResultsBox="true" MaxLength="100" IsCaseSensitive="false" LoadingMessage="Searching. Please Wait..." > |
</telerik:RadComboBox> |
When the user types more than 2 characters we go off and try to bring back results to display and that works just fine - when niothing is found however we see the text No Matches which is great, but what I need to have happen is for focus to leave this rad combobox from the code behind within :-
protected void radComboFullname_ItemsRequested(object o, Telerik.Web.UI.RadComboBoxItemsRequestedEventArgs e)
{
if (e.Text.Trim().Length >= 2)
{
}
else
{
//move focus off the control
}
}
How can i accomplish this?
The javascript we use is also as follows:-function RequestingHandler(sender, eventArgs) {
//restrict ajax request until after 2 chars
if (eventArgs.get_text().length < 2)
eventArgs.set_cancel(true)
else
eventArgs.set_cancel(false);
}