title: how to get the attribute values of the table row using jquery?
body: <p>I have a following razor to create a table.</p>
  
  <pre><code>@model IEnumerable&lt;iBoxV5.Model.Common.AdvancedSearch&gt;
  &lt;table id="SearchFieldsTable"&gt;
    &lt;thead&gt;
      &lt;tr&gt;
      &lt;th&gt;
          ColumnName
      &lt;/th&gt;
      &lt;th&gt;
          FilterValues
      &lt;/th&gt;
      &lt;th&gt;Updated Before&lt;/th&gt;
      &lt;/tr&gt;
  &lt;/thead&gt;
  &lt;tbody&gt;
  @foreach (var item in Model)
  {
  &lt;tr ColumnName=@item.ColumnName DatabaseColumn=@item.DatabaseColumn DisplayName=@item.DisplayName Datatype=@item.Datatype id=@(index++)&gt;
      &lt;td&gt;
          @Html.DisplayFor(modelItem =&gt; item.ColumnName)
      &lt;/td&gt;
      &lt;td&gt;
          @Html.TextBoxFor(modelItem =&gt; item.FilterValue, new { @class = "FrmTextBox advSearch" });
  
          @Html.TextBoxFor(modelItem =&gt; item.FilterValue, new { @class = "FrmTextBox advSearch" });
      &lt;/td&gt;
      &lt;td&gt;
          @Html.TextBoxFor(modelItem =&gt; item.FilterValueTo, new { @class = "FrmTextBox advSearch" });
      &lt;/td&gt;
  &lt;/tr&gt;
  }
  &lt;/tbody&gt;
  &lt;/table&gt;
  </code></pre>
  
  <p>And In the above I have added few attributes for the  like ColumnName.</p>
  
  <p>I wants to build a JSON for the each row of the Table.</p>
  
  <p>I tried with the following jquery Snippet.</p>
  
  <pre><code>var SearchFieldsTable = $("#SearchFieldsTable tbody");
  
  var trows = SearchFieldsTable[0].rows;
  
  $.each(trows, function (index, row) {
      var ColumnName=$(row).attr("ColumnName");
  });
  </code></pre>
  
  <p>But the above is not returning the ColumnName I expected.</p>