This is a migrated thread and some comments may be shown as answers.

[Solved] Grid Ajax Binding Select never gets called

0 Answers 55 Views
Grid
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Solomon
Top achievements
Rank 1
Solomon asked on 12 Apr 2011, 07:06 AM
the underlying code is supposed to call an actionresult on ajax select. But Table rerenders using the initial ActionResult on paging.

@(
 Html.Telerik().Grid(Model).Name("tbl_codes")
        .DataBinding(binding => binding.Ajax().Enabled(true)
            .Select("GET_TABLEFILE_LISTS", "Admin", new { TableFileID = Request["TableFileID"], StartLetter = Request["StartLetter"] })
        )
        .Pageable()
    .Filterable()
        .RowAction(r =>
            {
                r.HtmlAttributes["id"] = r.DataItem.ID;
            }
        )
    .Columns(col =>
    {
        col.Template(
           @<text>
               <a href="#">Edit</a>
          </text>
         ).Width(30);
        col.Bound(o => o.ItemCode).Title("Code").Width(90);
        col.Bound(o => o.Description).Title("Description");
        col.Bound(o => o.INIT_CODE).Title("Initials").Width(90);
        col.Template(
            @<text>
               @Html.RadioButton("DefaultID", @item.ID, (@item.CHD_DEFAULTID == @item.ID), new { style = "width:auto;" })
            </text>
            ).Title("Set Default").HtmlAttributes(new { style = "text-align:center" }).Width(40);
        col.Template(
            @<text>
                <a href="#">Delete</a>
            </text>
            ).Width(30);
    })
        .ClientEvents(c => c.OnRowDataBound("onRowBound"))
        .Sortable()
         
  )

Tags
Grid
Asked by
Solomon
Top achievements
Rank 1
Share this question
or