I am using Html.Grid in my asp.net MVC2 application.
The grid contains checkboxes per row.
<%= Html.Grid<MyViewModel>(Model.MyList)
.Columns( column => {
column.For(x => Html.CheckBox("Select", false, new { id = x.ID })).DoNotEncode();
I need to loop through the checked records and action them. How can I retrieve the checked id values when I do a postback on a button click.
Thanks :)
You can add like this
it will add checkbox on each row.