Hi,
I have created combox as below.
I am unable to select the same value from the combo box which I have selected previously.
Scenario: First I have selected a value from the combobox and then I clicked the button (ajax implemented) which will empty the combobox. Again I want to select the same value from the combobox but unfortunately I am not able to select it. Is there is a problem in my code.
Am using telerik version:2009.2.701.35. Please help me at the earliest
Regards,
Sathies
I have created combox as below.
| <div> |
| <asp:scriptmanager ID="Scriptmanager1" runat="server"></asp:scriptmanager> |
| <telerik:RadAjaxManager ID="RadAjaxManager1" runat="server"> |
| </telerik:RadAjaxManager> |
| <div id="s" runat="server"> |
| <telerik:RadComboBox ID="RadComboBox4" EnableViewState="false" EnableItemCaching="true" |
| EnableLoadOnDemand="true" runat="server" |
| onitemsrequested="RadComboBox4_ItemsRequested"> |
| </telerik:RadComboBox> |
| </div> |
| <asp:Button ID="Button1" runat="server" Text="Ajax" onclick="Button1_Click" /> |
| <asp:SqlDataSource ID="SqlDataSource1" |
| ConnectionString="<%$ ConnectionStrings:NorthwindConnectionString %>" |
| ProviderName="System.Data.SqlClient" |
| SelectCommand="SELECT * FROM Customers" runat="server"></asp:SqlDataSource> |
| </div> |
| protected void Page_Load(object sender, EventArgs e) |
| { |
| RadAjaxManager1.AjaxSettings.AddAjaxSetting(Button1, s, null); |
| } |
| protected void RadComboBox4_ItemsRequested(object o, Telerik.Web.UI.RadComboBoxItemsRequestedEventArgs e) |
| { |
| RadComboBox4.DataSourceID = "SqlDataSource1"; |
| string selectCommand = "SELECT * FROM CUSTOMERS WHERE CompanyName LIKE '" + |
| e.Text + "%'"; |
| SqlDataSource1.SelectCommand = selectCommand; |
| RadComboBox4.DataTextField = "CompanyName"; |
| RadComboBox4.DataValueField="CustomerID"; |
| RadComboBox4.DataBind(); |
| } |
| protected void Button1_Click(object sender, EventArgs e) |
| { |
| RadComboBox4.Text = RadComboBox4.EmptyMessage; |
| } |
I am unable to select the same value from the combo box which I have selected previously.
Scenario: First I have selected a value from the combobox and then I clicked the button (ajax implemented) which will empty the combobox. Again I want to select the same value from the combobox but unfortunately I am not able to select it. Is there is a problem in my code.
Am using telerik version:2009.2.701.35. Please help me at the earliest
Regards,
Sathies