mardi 3 novembre 2015

i want to show the row which it,s checkbox was checked in datagridview and hide the others rows unchecked

i have a datagridview and i have a column of checkboxes my code is

private void button2_Click(object sender, EventArgs e)
{        
    DataGridViewRow row = new DataGridViewRow();
    for (int i = 0; i < dataGridView1.Rows.Count; ++i)
    {
        row = dataGridView1.Rows[i];

        if (Convert.ToBoolean(row.Cells[0].Value) == true)
        {
            this.dataGridView1.DataSource =
        }
    }
}




Aucun commentaire:

Enregistrer un commentaire