This question is locked. New answers and comments are not allowed.
I am looking at the example and i have one question
<%= Html.Telerik().Grid<Order>()
.DataBinding(dataBinding => dataBinding.Ajax().Select("_AjaxBinding", "Grid"))
.Name("Grid")
.Columns(columns =>
{
columns.Bound(o => o.OrderID).Width(81);
columns.Bound(o => o.Customer.ContactName).Width(200);
columns.Bound(o => o.ShipAddress);
columns.Bound(o => o.OrderDate).Format("{0:MM/dd/yyyy}").Width(100);
})
%>
[GridAction]
public ActionResult _AjaxBinding()
{
return View(new GridModel(GetOrders()));
}
I get all the orders from the database in memory and using linq i extract the orders corresponding to the current page?
I hope i got this wrong because normally you extract from the database only the records correspnding to the current page, sorting, etc..
Later edit: Because of my long nose i didn't see custom binding which is what i was talking about. Sorry for posting such silly question.
<%= Html.Telerik().Grid<Order>()
.DataBinding(dataBinding => dataBinding.Ajax().Select("_AjaxBinding", "Grid"))
.Name("Grid")
.Columns(columns =>
{
columns.Bound(o => o.OrderID).Width(81);
columns.Bound(o => o.Customer.ContactName).Width(200);
columns.Bound(o => o.ShipAddress);
columns.Bound(o => o.OrderDate).Format("{0:MM/dd/yyyy}").Width(100);
})
%>
[GridAction]
public ActionResult _AjaxBinding()
{
return View(new GridModel(GetOrders()));
}
I get all the orders from the database in memory and using linq i extract the orders corresponding to the current page?
I hope i got this wrong because normally you extract from the database only the records correspnding to the current page, sorting, etc..
Later edit: Because of my long nose i didn't see custom binding which is what i was talking about. Sorry for posting such silly question.