dynamicly highlight row in grid or dynamicly set page of grid (JS or on server)

Apr 16, 2013 at 8:03 AM
Hi, is it please possible in JS or in controller highlight specific row in grid, for example I want to highlight row number 3 in grid.
And 2nd question is: Is it possible to dynamicly change page? For example I want to set page on grid to 3?

In JS or on server(controller).
Thank you very much.
Apr 16, 2013 at 8:51 AM

You can determine the condition to apply custom css classes to grid rows and define custom css rules:
@Html.Grid(Model).Columns(...).SetRowCssClasses(item => item.Customer.IsVip ? "warning" : string.Empty);

tr.warning>td {
background-color: #FCF8E3;
See sample app in the repository for more infomation

What reason in dynamically changing page? Gridmvc automatically detect current page by parameters, passed to querystring. You can create custom grid pager, inherited from IGridPager interface - if you want to provide pager options not from query string source.