This question is locked. New answers and comments are not allowed.
Hello,
I have a problem using the method Style(GridPagerStyles.PageInput) of Pageable. When the browser renders the page the first time shows the text "of {0}". The Extensions for ASP.NET MVC Q2 2010 Beta Live Examples have the same problem.
I'm using MVC2 and Telerik_Extensions_for_ASPNET_MVC_Q2_2010_2_713.
Could you indicate me how I should fix this problem?
Thanks.
Code:
In TestSampleController.cs
In the view,
I have a problem using the method Style(GridPagerStyles.PageInput) of Pageable. When the browser renders the page the first time shows the text "of {0}". The Extensions for ASP.NET MVC Q2 2010 Beta Live Examples have the same problem.
I'm using MVC2 and Telerik_Extensions_for_ASPNET_MVC_Q2_2010_2_713.
Could you indicate me how I should fix this problem?
Thanks.
Code:
In TestSampleController.cs
public ActionResult TestSample(){ int total; //First Loading ViewData["PageSize"] = 10; IList<CZone> zones = _zoneRepo.GetAll(0, 10, out total); ViewData["Total"] = total; return View(zones);}[GridAction(EnableCustomBinding = true)]public ActionResult _TestSample(GridCommand command){ int total; return View(new GridModel<CZone> { Data = _zoneRepo.GetAll((command.Page - 1) * command.PageSize, command.PageSize, out total), Total = total });}In the view,
<%= Html.Telerik().Grid(Model) .Name("GridZone") .PrefixUrlParameters(false) .EnableCustomBinding(true) .Columns(columns => { columns.Bound(z => z.Id); columns.Bound(z => z.CodeZone).Title("Zone Code"); columns.Bound(z => z.DescZone).Title("Zone Name"); }) .DataBinding(dataBinding => dataBinding.Ajax().Select("_TestSample", "TestSample")) .Pageable(pager => { pager.Total((int)ViewData["Total"]); pager.PageSize((int)ViewData["PageSize"]); pager.Style(GridPagerStyles.PageInput | GridPagerStyles.NextPreviousAndNumeric); }) .Scrollable()%>