Home > Net >  On delete selected row dataGridView control
On delete selected row dataGridView control

Time:02-28

From the Internet to find delete selected dataGridView control statements, as follows:

Foreach (dataGridViewRow r in dataGridView1. SelectedRows)
{
if (! R.I sNewRow)
{
DataGridView1. Rows. Remove (r);
}
}

Compiled an error: CS0246 failed to find the type or namespace name "dataGridViewRow" (whether or not the lack of a using directive or assembly reference?) WindowsFormsApp1 D: \ \ XML data table serialization \ WindowsFormsApp1 \ WindowsFormsApp1 \ Form1 cs 74 activity

Please comment.

CodePudding user response:

DataGridViewRow into dataGridViewRow
  •  Tags:  
  • C#
  • Related