This question is locked. New answers and comments are not allowed.
Action<int, string> addValueColumn = (i, title) => { columns.Bound(u => u.Column[i].val).Title(title); }; for (int i = 0; i < Model.FirstOrDefault().Column.Count; i++) { addValueColumn(i, Model.FirstOrDefault().Column[i].label); }
This works fine when first getting the grid with Ajax. When sorting the column values disappear. Can this be resolved?