TextChanged
The TextChanged event occurs when the text in the input area of RadComboBox changes. This can be due to the user typing in custom text (if the AllowCustomText property is True) or to changing the selected item. When the user types in the input area, TextChanged does not occur until the user hits Enter or clicks outside the combobox. When the selection changes, TextChanged only occurs if a new item is selected.
The TextChanged event does not fire unless the AutoPostBack property is True .
The TextChanged event handler receives two arguments:
-
The RadComboBox that is loading items. This argument is of type object, but can be cast to the RadComboBox type.
-
An EventArgs object. This is the standard ASP.NET EventArgs object.
Use the TextChanged event handler to respond in server-side code when text in the input area changes:
<telerik:radcombobox
id="RadComboBox1"
runat="server"
ontextchanged="RadComboBox1_TextChanged"
allowcustomtext="True"
autopostback="True">
</telerik:radcombobox>
protected void RadComboBox1_TextChanged(object sender, EventArgs e)
{
TextBox1.Text = RadComboBox1.Text;
}