We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date
close icon

adding searchable combo box inside the sycfusion grid

I would like to add searchable combobox inside the syncfusion grid and also i wants to save the combo box value in to the data base . I am using the sycfusion version 8.103.0.30 . Please advice.

Thanks and Regards,
Faizal Ahmed.H


3 Replies

BM Bharath M Syncfusion Team September 22, 2010 04:55 AM UTC

Hi Faizal,

We regret for the inconvenience caused.

Before I proceed to give you a solution, I would like to know more about your requirement. Could you please provide me more information regarding, how you are going to use the Searchable ComboBox in Grid for example filtering, editing etc.

The information provided would be of great help in resolving the issue

Regards,
Bharath M




PF Peter Fithian October 27, 2010 04:52 PM UTC

Can anyone at Syncfusion tell me why this posting exists in your 'Forums' when NO solution is presented? This is a USELESS posting containing nothing of value.



BM Bharath M Syncfusion Team November 2, 2010 06:42 AM UTC

Hi Peter,

We are sorry that the previous response in the thread has not been useful for you. We were looking for more information from the user to provide a complete solution as the requirement was partially supported by us and we wanted clarity on the scenario of the forum user.

Here is generic response on the query which would add useful information to this thread. Currently, we can add the Searchable ComboBox to grid in two ways one is as an Edit time control(EditItemTemplate) and another is as a Browse time control(ItemTemplate).

Following code illustrates how to add Edit Item Template

[ASPX]

. . .

< . . . >


<%--For EditItemTemplate - As Edit time control--%>

OnTextChanged="auto_TextChanged">



<%--For ItemTemplate - As Browse mode control--%>

OnTextChanged="auto_TextChanged">



<. . . >

. . .


[CS]

protected void auto_ProvideChoiceListOnCallback(object sender, ACUserChoiceListEventArgs e)
{
e.ChoiceList = GetDataSource().FindAll(l => l.Number.ToString().StartsWith(e.Key)).Select(l => l.Number).ToArray();
}

protected void auto_TextChanged(object sender, EventArgs e)
{
AutoCompleteTextBox auto = sender as AutoCompleteTextBox;
GridCell cell = auto.NamingContainer as GridCell;

//To save the combo box value to a database – please use the following line of code

// Code to update the changed text value in Record Object. And you can save the changed values in DataBase in DataSourceControlRowUpdating/Adding event
cell.Row.Record.SetValue(cell.ColumnDescriptor.Name, auto.Text);

}


Please refer the attachment for sample application.

P.S: Currently we don't have support for adding searchable ComboBox as a filter control, we have already logged feature request report for this. If you like to know more on this feature request, you may check with us by logging an incident using our direct trac support system.

Let me know if you have any concerns.

Regards,
Bharath M




AutoComplete_a6b14f9a.zip

Loader.
Live Chat Icon For mobile
Up arrow icon