title: Datagrid checkbox column select not working right
body: <p>I want to have a column with checkboxes that when ever the user clicks them, they select  their own row (hightlight it). I have come up with this code, with does not do the job, how can I fix it?</p>
  
  <p>Is there a better way of doing this? (The row stays highlighter even after I "uncheck" the checkbox).</p>
  
  <pre><code> private void dataGrid_CellClick(object sender, DataGridViewCellEventArgs e)
          {
              if (e.ColumnIndex == 0 &amp;&amp; e.RowIndex != -1) 
              {
                  if (Convert.ToBoolean(dataGrid.Rows[e.RowIndex].Cells[0].Value) == true)
                      dataGrid.Rows[e.RowIndex].Selected = false;
                  else if (Convert.ToBoolean(dataGrid.Rows[e.RowIndex].Cells[0].Value) == false)
                      dataGrid.Rows[e.RowIndex].Selected = true;
              }
          }
  </code></pre>