title: How to set webgrid row style inline
body: <p>I am using a <strong>WebGrid</strong> to display a List of Items, some items in the list are disabled, so I would like to make it dimmed in the grid, to do that I must set the row class to be dimmed if the item is disabled, I do not know how to set the row class according to a condition </p>
  
  <p>This is my sample code</p>
  
  <pre><code>  var grid = new WebGrid(Model, canPage: true, rowsPerPage: 20);
                  @grid.GetHtml(tableStyle: "grid",
                                  rowStyle: "gridrow",
                                  alternatingRowStyle: "gridrow_alternate",
                                  mode: WebGridPagerModes.All,
                                  numericLinksCount: 10,
                                  columns: grid.Columns(
                                      grid.Column("Name", "Name", item =&gt; (item.LocationData[0].Name), canSort: true, style: "width:60%"),
                                      grid.Column("Url", "Url", canSort: true, style: "width:60%"),
                                      grid.Column("Edit", "", @&lt;a href='../VenHome/Edit/@item.ID' &gt;&lt;img src='/content/icons/edit.png'
                                          alt='Edit' /&gt;
                                      &lt;/a&gt;, style: "width:150px"),
                                      grid.Column("Delete", "", @&lt;a href='#' id='Delete' itemId='@item.ID' title='@item.LocationData[0].Name'&gt;&lt;img
                                          src='/content/icons/delete.png' alt='Delete' /&gt;
                                      &lt;/a&gt;, style: "width:150px"),
                                      grid.Column("Details", "", @&lt;a href="../VenHome/Details/@item.Id" title="Details"&gt;
                                          &lt;img src="../../Content/Icons/Details.png" alt="Details" /&gt;&lt;/a&gt;)
                                      ));
  
              }
  </code></pre>