Is there a way to assign custom data attributes for table rows generated by the WebGrid helper in Asp.Net MVC?
What I would like to end up with is something like this:
<tr data-foo="foo"></tr>
Is there a way to assign custom data attributes for table rows generated by the WebGrid helper in Asp.Net MVC?
What I would like to end up with is something like this:
<tr data-foo="foo"></tr>
No, AFAIK that's not possible. The best you could do on a tr
is to apply a style and an alternating row style. I'd recommend MvcContrib Grid or Telerik Mvc Grid as more advanced alternatives to Microsoft's WebGrid helper.