I use AutoComplete in grid column
But i can't send AutoComplete value to server
Please help me.
But i can't send AutoComplete value to server
Please help me.
@(Html.Kendo().Grid<
MvcApplication10.Models.Product
>()
.Name("Customers")
.ToolBar(tb => tb.Create())
.Pageable()
.Columns(cols =>
{
cols.Bound(c => c.Name).EditorTemplateName("products");
cols.Bound(c => c.Number);
cols.Command(cmd =>
{
cmd.Edit();
cmd.Destroy();
});
})
.DataSource(dataSource => dataSource.Ajax()
.Model(model => model.Id(c => c.ProductID))
.Read("GetCustomers", "Product")
.Update("UpdateCustomer", "Product")
.Create("InsertCustomer", "Product")
.Destroy("DeleteCustomer", "Product"))
)
and AutoComplete file(products.cshtml) is placed in EditorTemplate folder in this view
@(Html.Kendo().AutoComplete()
.Name("products")
.DataTextField("Name")
.Filter("contains")
.MinLength(3)
.HtmlAttributes(new { style = "width:250px" })
.DataSource(source => {
source.Read(read =>
{
read.Action("GetProducts", "AutoComplate");
})
.ServerFiltering(false);
})
)