I just tried your code:
private void button1_Click(object sender, EventArgs e)
{
dgvData.Rows.Add(true);
dgvData.Rows.Add(false);
dgvData.Rows.Add(true);
dgvData.Rows.Add(false);
}
private void button2_Click(object sender, EventArgs e)
{
if (dgvData.Rows[dgvData.CurrentCell.RowIndex].Cells[dgvData.Columns["chkBox"].Index].Value != null)
{
MessageBox.Show(dgvData.Rows[dgvData.CurrentCell.RowIndex].Cells[dgvData.Columns["chkBox"].Index].Value.ToString());
}
}
And all I get is "true" or "false", as I would expect.
Are you sure it is executing that code? Because you would not normally get a MessageBox - you would get a NullReferenceException as the value you are calling ToString on would have to be null - which won't work!