说明:
(1)dgvGoods 是DataGridView名
(2)index 是最大行索引
DataGridViewRow row = new DataGridViewRow();
int index = dgvGoods.Rows.Add(row);
dgvGoods.Rows[index].Cells["列名1"].Value = 值1;
dgvGoods.Rows[index].Cells["列名2"].Value = 值2;
、、、
2023-12-18 11:56:22
说明:
(1)dgvGoods 是DataGridView名
(2)index 是最大行索引
DataGridViewRow row = new DataGridViewRow();
int index = dgvGoods.Rows.Add(row);
dgvGoods.Rows[index].Cells["列名1"].Value = 值1;
dgvGoods.Rows[index].Cells["列名2"].Value = 值2;
、、、